JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 11
  • Score
    100M100P100Q97152F
  • License MIT

Epsimo CLI - TUI dashboard, smart CLI, AI agents, projects, threads, Virtual Database, and deployments from the terminal.

Package Exports

    This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (epsimo-cli) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

    Readme

    Epsimo Agent Framework

    Beta Release โ€” Build sophisticated AI-powered applications with agents, persistent threads, and Virtual Database state management.

    License: MIT Version Skills npm

    The Epsimo Agent Framework provides a unified CLI, Python SDK, and React UI Kit for building AI applications with:

    • ๐Ÿค– Multi-agent orchestration
    • ๐Ÿ’พ Virtual Database (thread-based persistent state)
    • ๐Ÿ’ฌ Streaming conversations with tool support
    • ๐ŸŽจ Pre-built React components
    • ๐Ÿ”Œ Extensible tool library

    Base URL: https://api.epsimoagents.com
    Frontend: https://app.epsimoagents.com


    ๐Ÿ“ฆ Installation

    Install as a skill for Claude Code, Cursor, Cline, Windsurf, and 30+ other AI coding agents:

    npx skills add thierryteisseire/epsimo-agent

    This installs the skill across all your AI agents in one command! The skill helps agents:

    • Set up Epsimo projects quickly
    • Manage agents and threads
    • Query the Virtual Database
    • Deploy configurations
    • Handle authentication flows

    npm Package (Global Installation)

    npm install -g epsimo-cli

    Python SDK & CLI

    # Install from PyPI (coming soon)
    pip install epsimo-agent
    
    # Or install from source
    git clone https://github.com/thierryteisseire/epsimo-cli.git
    cd epsimo-cli
    pip install -r requirements.txt
    
    # Make CLI executable
    chmod +x epsimo/cli.py
    export PATH="$PATH:$(pwd)/epsimo"

    ๐Ÿš€ Quick Start

    1. Authentication

    # Login to Epsimo
    epsimo auth login
    
    # Check who you're logged in as
    epsimo whoami
    
    # Check thread/credit balance
    epsimo credits balance

    2. Create Your First Project

    # Create a new Next.js project with Epsimo
    epsimo create "My AI App"
    
    # Or initialize in existing directory
    cd my-existing-project
    epsimo init

    3. Deploy Configuration

    # Sync your epsimo.yaml to the platform
    epsimo deploy

    ๐Ÿ› ๏ธ CLI Reference

    Authentication Commands

    epsimo auth login              # Interactive login
    epsimo whoami                  # Display current user info

    Project Management

    epsimo projects                # List all projects
    epsimo create <name>           # Scaffold a new Next.js app
    epsimo init                    # Initialize existing directory
    epsimo deploy                  # Deploy epsimo.yaml configuration

    Virtual Database

    epsimo db query --project-id <P_ID> --thread-id <T_ID>
    epsimo db set --project-id <P_ID> --thread-id <T_ID> --key <K> --value <V>
    epsimo db get --project-id <P_ID> --thread-id <T_ID> --key <K>

    Credits & Billing

    epsimo credits balance                  # Check thread balance
    epsimo credits buy --quantity <N>       # Generate Stripe checkout URL

    Resource Listing

    epsimo assistants --project-id <P_ID>  # List assistants
    epsimo threads --project-id <P_ID>     # List threads

    ๐Ÿ“š Python SDK

    Installation

    from epsimo import EpsimoClient
    
    # Initialize with API key (JWT token)
    client = EpsimoClient(api_key="your-token-here")
    
    # Or use environment variable
    # export EPSIMO_API_KEY=your-token-here
    client = EpsimoClient()

    Virtual Database Access

    # Get all structured data from a thread
    db_state = client.db.get_all(project_id, thread_id)
    
    # Get specific key
    user_prefs = client.db.get(project_id, thread_id, "user_preferences")
    print(f"Theme: {user_prefs.get('theme')}")
    
    # Set value (for seeding/testing)
    client.db.set(project_id, thread_id, "status", "active")

    Streaming Conversations

    # Stream assistant responses
    for chunk in client.threads.run_stream(
        project_id, 
        thread_id, 
        assistant_id, 
        "Hello, how can you help me?"
    ):
        print(chunk, end="", flush=True)

    Managing Resources

    # Projects
    projects = client.projects.list()
    project = client.projects.create(name="My Project", description="...")
    project_details = client.projects.get(project_id)
    
    # Assistants
    assistants = client.assistants.list(project_id)
    assistant = client.assistants.create(project_id, config={...})
    
    # Threads
    threads = client.threads.list(project_id)
    thread = client.threads.create(project_id, assistant_id=assistant_id)
    
    # Files
    files = client.files.list(project_id, assistant_id)
    file = client.files.upload(project_id, assistant_id, file_path="document.pdf")
    
    # Credits
    balance = client.credits.get_balance()
    checkout_url = client.credits.create_checkout_session(quantity=1000, amount=100.0)

    ๐ŸŽจ React UI Kit

    ThreadChat Component

    import { ThreadChat } from "@/components/epsimo";
    
    export default function App() {
      return (
        <ThreadChat 
          assistantId="your-assistant-id"
          projectId="your-project-id"
          placeholder="Ask me anything..."
        />
      );
    }

    useChat Hook (Headless)

    import { useChat } from "@/hooks/epsimo";
    
    export default function CustomChat() {
      const { messages, sendMessage, isLoading } = useChat({
        projectId: "...",
        threadId: "...",
        assistantId: "..."
      });
    
      return (
        <div>
          {messages.map(msg => (
            <div key={msg.id}>{msg.content}</div>
          ))}
          <button onClick={() => sendMessage("Hello")} disabled={isLoading}>
            Send
          </button>
        </div>
      );
    }

    ๐Ÿงช Tool Library

    The framework includes reusable tool schemas in epsimo/tools/library.yaml:

    Available Tools

    Tool Type Description
    database_sync function Persist structured JSON to thread state (Virtual DB)
    web_search_tavily search_tavily Advanced web search with source attribution
    web_search_ddg ddg_search Fast DuckDuckGo search for simple queries
    retrieval_optimized retrieval High-accuracy document search in uploaded files
    task_management function Track and update user tasks

    Using Tools in Assistants

    # epsimo.yaml
    assistants:
      - name: "Research Assistant"
        model: "gpt-4o"
        instructions: "You help with research tasks"
        tools:
          - type: search_tavily
            max_results: 5
          - type: function
            name: update_database
            description: "Save research findings"
            parameters:
              type: object
              properties:
                key: { type: string }
                value: { type: object }

    ๐Ÿ’พ Virtual Database Pattern

    Threads serve as persistent, structured storage โ€” eliminating the need for a separate database.

    How It Works

    1. Agent writes to DB using the update_database tool
    2. Data persists in thread state
    3. Query from SDK or CLI:
    # Python SDK
    preferences = client.db.get(project_id, thread_id, "user_preferences")
    
    # CLI
    epsimo db query --project-id P123 --thread-id T456

    Benefits

    • โœ… Zero database configuration
    • โœ… Data naturally partitioned by conversation
    • โœ… Agent always "knows" what's in its DB
    • โœ… Queryable from both agent and application code

    See docs/virtual_db_guide.md for detailed guide.


    ๐Ÿ” Authentication & Security

    Environment Variables

    # .env file (never commit!)
    EPSIMO_API_KEY=your-jwt-token-here
    EPSIMO_EMAIL=your@email.com
    EPSIMO_PASSWORD=your-password  # Only for automated scripts

    Token Management

    from epsimo.auth import get_token, perform_login
    
    # Login programmatically
    token = perform_login("your@email.com", "password")
    
    # Get cached token (auto-refreshes if expired)
    token = get_token()

    Token Storage: Tokens are stored in ~/.epsimo_token (configurable via TOKEN_FILE in auth.py)

    Security Best Practices:

    • Never commit .epsimo_token or .env files
    • Use environment variables in production
    • Rotate tokens regularly
    • Use project-specific tokens for multi-tenant apps

    ๐Ÿ“– API Reference

    See references/api_reference.md for comprehensive endpoint documentation including:

    • Authentication flows
    • Request/response schemas
    • HTTP status codes
    • Error handling patterns
    • Rate limits

    ๐Ÿงช Verification & Testing

    # Verify skill is correctly configured
    python3 verify_skill.py
    
    # Run E2E test suite
    python3 scripts/test_all_skills.py
    
    # Test streaming functionality
    python3 scripts/test_streaming.py
    
    # Test Virtual DB
    python3 scripts/test_vdb.py

    ๐Ÿ“ Project Structure

    epsimo-cli/
    โ”œโ”€โ”€ epsimo/
    โ”‚   โ”œโ”€โ”€ cli.py              # Unified CLI
    โ”‚   โ”œโ”€โ”€ client.py           # Main SDK client
    โ”‚   โ”œโ”€โ”€ auth.py             # Authentication logic
    โ”‚   โ”œโ”€โ”€ resources/          # Resource-specific clients
    โ”‚   โ”‚   โ”œโ”€โ”€ projects.py
    โ”‚   โ”‚   โ”œโ”€โ”€ assistants.py
    โ”‚   โ”‚   โ”œโ”€โ”€ threads.py
    โ”‚   โ”‚   โ”œโ”€โ”€ files.py
    โ”‚   โ”‚   โ”œโ”€โ”€ credits.py
    โ”‚   โ”‚   โ””โ”€โ”€ db.py
    โ”‚   โ”œโ”€โ”€ tools/
    โ”‚   โ”‚   โ””โ”€โ”€ library.yaml    # Reusable tool schemas
    โ”‚   โ””โ”€โ”€ templates/          # Project scaffolding templates
    โ”œโ”€โ”€ scripts/                # Helper scripts and examples
    โ”œโ”€โ”€ docs/                   # Additional documentation
    โ”œโ”€โ”€ references/             # API reference docs
    โ”œโ”€โ”€ SKILL.md                # Main skill documentation
    โ””โ”€โ”€ README.md               # This file

    ๐Ÿค Contributing

    Contributions are welcome! Please open an issue or pull request on GitHub.


    ๐Ÿ“„ License

    MIT License - see LICENSE for details.


    Installation & Discovery

    Documentation

    Platform


    Questions? Open an issue on GitHub or check the API Reference.