Skip to main content

A modular AI agent.

Project description

Proto-Agent

An educational AI agent framework demonstrating capability-based security and modular toolkit architecture. Built for learning secure AI agent patterns with human oversight and permission controls.

Features

  • Capability-based security with granular permission controls
  • CLI tool with human-in-the-loop approval for dangerous operations
  • Python framework for building custom agents with programmatic control
  • Modular toolkits for file operations, system monitoring, and version control
  • Educational focus - clear, readable code demonstrating AI agent security patterns

Quick Start

Installation

pip install proto-agent

Configuration

Add your Gemini API key to the config directory:

# Linux/Mac: ~/.config/proto-agent/.env
# Windows: %APPDATA%\proto-agent\.env
echo "API_KEY=your_gemini_api_key_here" >> ~/.config/proto-agent/.env

CLI Usage

# Safe read-only analysis
proto-agent "Analyze this codebase structure" ./my_project --read-only

# Interactive execution with approval prompts
proto-agent "Run the test suite" ./my_project
# Prompts: "Allow execution of function 'run_python_file'? (y/N):"

Framework Usage

from proto_agent import Agent, AgentConfig
from proto_agent.tool_kits import FileOperationToolkit

# Autonomous mode - no human approval needed
agent = Agent(AgentConfig(
    api_key="your_gemini_api_key",
    working_directory="./my_project",
    tools=[FileOperationToolkit(
        enable_read=True,
        enable_write=False,    # Disable risky operations
        enable_execute=False
    ).tool]
))

response = agent.generate_content("Analyze this project's structure")
print(response.text)

Key Concepts

  • CLI Mode: Interactive approval prompts for dangerous operations
  • Framework Mode: Full programmatic control over permissions
  • Capability Flags: Enable/disable specific operations per toolkit
  • Human Oversight: Configurable approval gates for security

Available Toolkits

  • 📁 FileOperationToolkit: File reading, writing, and execution
  • 💻 SystemInfoToolkit: System monitoring and resource information
  • 🔧 GitToolkit: Version control operations with safety controls

Documentation

Educational Goals

Proto-Agent prioritizes learning and security over performance:

  • Demonstrates secure AI agent design patterns
  • Shows human-in-the-loop safety controls
  • Provides clear, modular architecture examples
  • Emphasizes permission-based security models

Perfect for developers learning about AI agents, security patterns, or needing a foundation for experimentation.

License

MIT License - see LICENSE file for details.


⭐ Star the repo to support educational AI agent development!

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

proto_agent-0.5.0.tar.gz (15.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

proto_agent-0.5.0-py3-none-any.whl (21.0 kB view details)

Uploaded Python 3

File details

Details for the file proto_agent-0.5.0.tar.gz.

File metadata

  • Download URL: proto_agent-0.5.0.tar.gz
  • Upload date:
  • Size: 15.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.8.3

File hashes

Hashes for proto_agent-0.5.0.tar.gz
Algorithm Hash digest
SHA256 045b9e1d6719d596b52a411fd14d51773c30829730d493d666bbc1cacc1595e8
MD5 9c715386ded872cb4b2a6ff7525ab813
BLAKE2b-256 a5a53a2357dc7d5c31a0a796c6dde932d27a2eb2348a48fb2f3d092263e99d09

See more details on using hashes here.

File details

Details for the file proto_agent-0.5.0-py3-none-any.whl.

File metadata

File hashes

Hashes for proto_agent-0.5.0-py3-none-any.whl
Algorithm Hash digest
SHA256 6aed9effd3552e84893713d1b3097bc2746147cf85a000d5605745ab7b0a2b20
MD5 84a5d0880eb9033e719e1ea5465b24ce
BLAKE2b-256 b352dd1aa493155455dbdf0635f15b8681439be8d97694d4e21a34daa1cf5c69

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page