Skip to main content

Victor

A contract-first agentic AI framework for building reliable agents across local and cloud models.

PyPI version Python 3.11+ Fast Checks Tests License: Apache 2.0 Docker


Victor gives you a typed Python framework, a service-first agent runtime, and a contract-first plugin ecosystem for building agents that can reason, call tools, run workflows, coordinate teams, and operate against project-local code intelligence.

It is designed for teams that need agent systems to be testable, extensible, observable, and portable across Anthropic, OpenAI-compatible providers, Gemini, Bedrock, local models, and air-gapped environments.

Why Victor

Capability What it gives you
Service-first runtime Chat, tools, sessions, context, provider routing, and recovery are owned by focused runtime services instead of a monolithic orchestrator.
StateGraph workflows Build typed graph workflows and use teams as graph nodes without inventing a separate multi-agent graph abstraction.
Local and cloud models Use cloud providers for capability, local providers for privacy/cost, and provider-specific caching strategies for performance.
Tool-rich execution Compose filesystem, git, shell, code search, graph, verification, Docker, web, testing, and refactoring tools.
Contract-first plugins Put domain behavior in sibling victor-* packages through victor-contracts and public framework extension contracts.
Project code intelligence Keep graph indexes, semantic search, conversations, and project memory in project-local state.

Quick Start

Path Commands Best for
Local model pipx install victor-ai
ollama pull qwen2.5-coder:7b
victor chat "Explain this repo"
Private, low-cost, air-gapped work
Cloud model pipx install victor-ai
export ANTHROPIC_API_KEY=...
victor chat --provider anthropic "Plan this refactor"
Highest model capability
Python API pip install victor-ai Embedding Victor in applications
Docker docker pull ghcr.io/vjsingh1984/victor:latest Isolated CLI/API runtime

Give Your Agent Durable Memory

Victor pairs with ProximaDB — a multi-model (vector + graph + document) context database by the same author — as its durable memory layer. Index any repository with the shared victor-codegraph chunker and get semantic recall ("where do we validate JWTs?") plus call-graph queries ("who calls parse_jwt?") that persist across sessions:

Quickstart: Durable Code Memory with ProximaDB — Docker + two pip installs, ~10 minutes.

Victor's embedded ProximaDB backends for project code intelligence are experimental, flag-gated previews — SQLite/LanceDB remain the defaults. The correlated graph+vector code-context backend (one entity = row + graph node + vector, TD-11/12/13) is roadmap, not shipped — see the roadmap and ProximaDB as the CCG Backend.

Python API

from victor.framework import Agent, EventType, ToolSet

agent = await Agent.create(
    provider="anthropic",
    tools=ToolSet.default(),
)

result = await agent.run("Explain the architecture of this codebase")
print(result.content)

async for event in agent.stream("Review the changed files"):
    if event.type == EventType.CONTENT:
        print(event.content, end="")

StateGraph Workflows

from typing import TypedDict

from victor.framework import END, StateGraph


class ReviewState(TypedDict):
    query: str
    findings: list[str]


async def inspect(state: ReviewState) -> ReviewState:
    return {**state, "findings": ["example finding"]}


graph = StateGraph(ReviewState)
graph.add_node("inspect", inspect)
graph.add_edge("inspect", END)

result = await graph.compile().invoke({"query": "review this module", "findings": []})

Architecture

The core rule is simple: interfaces compose framework APIs, framework APIs delegate to the service-first runtime, and domain packages plug in through SDK/public extension contracts.

Victor 0.7 architecture

Victor 0.7 makes the framework/plugin split explicit:

  • victor.framework is the stable public contract for agents, tools, StateGraph, workflows, events, and extension surfaces.
  • victor.agent is the internal runtime implementation behind that contract.
  • victor.agent.services owns effectful runtime behavior through ChatService, ToolService, SessionService, ContextService, ProviderService, and RecoveryService.
  • victor-contracts is the definition-layer contract for external verticals and plugins.
  • Sibling victor-* packages own domain behavior such as coding, DevOps, RAG, research, data analysis, and investment workflows.

Detailed references:

Plugin Ecosystem

External and first-party domain packages should use victor-contracts and public framework extension contracts. The root framework stays generic; domain-specific behavior belongs in plugins and vertical packages.

Package Focus
victor-coding Code review, editing, test generation, language tooling
victor-devops Infrastructure, containers, CI/CD, cloud operations
victor-rag Ingestion, retrieval, hybrid search, grounded answers
victor-dataanalysis Data cleaning, statistics, dataframe analysis, visualization
victor-research Source research, synthesis, fact checking
victor-invest Investment research workflows and dashboard/API integration
victor-registry Package marketplace and registry metadata

Plugin rules:

  • Use the victor.plugins entry point as the canonical discovery seam.
  • Register capabilities through VictorPlugin.register(context).
  • Import from victor_contracts, victor.framework.extensions, or documented public APIs.
  • Do not import victor.agent.* or private root runtime internals from external packages.

Use Cases

  • Build local or cloud-backed coding agents that can inspect files, search graphs, run tests, and produce review findings.
  • Compose workflow agents with typed StateGraph nodes, deterministic handoffs, and resumable execution.
  • Run tool-using assistants through CLI, TUI, HTTP API, MCP, or embedded Python.
  • Build domain plugins without copying framework internals into vertical packages.
  • Keep project code intelligence local while preserving global preferences, learning, and provider settings separately.

State and Code Intelligence

Victor uses a two-database model:

Scope Location Purpose
Global database ~/.victor/victor.db Settings, API keys, profiles, RL outcomes, tool/model preferences, cross-project patterns
Project database ./.victor/project.db Graph nodes/edges, conversations, project sessions, entity memory, change tracking

Project code intelligence is derived, rebuildable state. Graph indexes, vector indexes, file watcher state, and .victor/ runtime artifacts should not become source-of-truth release artifacts.

Development

python -m venv .venv
source .venv/bin/activate
# victor-contracts first so victor-ai resolves the in-repo SDK, not PyPI
pip install -e ./victor-contracts -e ".[dev]"

make test-quick
make test
make lint
make check-repo-hygiene

Optional extras

The base install degrades gracefully when optional dependencies are absent (lazy/guarded imports). Install an extra only when you want that capability:

pip install -e ".[web]"          # headless browser rendering + trafilatura extraction
                                #   (web_fetch render=browser; DDG browser fallback)
                                #   then: playwright install chromium
pip install -e ".[embeddings]"   # sentence-transformers + lancedb for semantic search
pip install -e ".[docker]"       # sandboxed code execution / container deploy
pip install -e ".[langchain]"    # adapt LangChain tools as native Victor tools

Subprojects are scoped:

npm --prefix vscode-victor run compile
cd rust && cargo test

Documentation

Contributing

Start with CONTRIBUTING.md and the architecture overview; see the development docs for setup, code style, and the PR workflow. Keep changes scoped, prefer public framework/SDK contracts over internal imports, and update docs/tests when public behavior changes.

License

Apache License 2.0. See LICENSE.

Release files for victor-ai 0.9.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for victor-ai 0.9.1
File Size Uploaded
victor_ai-0.9.1.tar.gz 7.4 MB Details

Built distribution (wheel)

Table of built distributions (wheels) for victor-ai 0.9.1
File Interpreter ABI Platform
victor_ai-0.9.1-py3-none-any.whl Python 3 none any Details

Total release size: 15.6 MB

Release files / victor_ai-0.9.1.tar.gz

Download URL victor_ai-0.9.1.tar.gz
Size 7.4 MB
Tags Source
SHA-256 checksum
How to use checksums
4725e6ffb97d0cf96fcca025602533d475267979b537782d8dfdd53a74b3c78e
BLAKE2b-256 checksum
How to use checksums
d1bd7e5fc340819f5d1f0b934b006a05966a55e987505cefbd58bab4ddd2dc58
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 7, 2026.

Transparency log

Release files / victor_ai-0.9.1-py3-none-any.whl

Download URL victor_ai-0.9.1-py3-none-any.whl
Size 8.1 MB
Tags Python 3
SHA-256 checksum
How to use checksums
c3b1bd6fb098d6042ac9979b5cc1f548d1fbb061955f89e3bc0025b196f28d52
BLAKE2b-256 checksum
How to use checksums
f6ac66850a613d60a7f25de4855718d61e4da68aeba5f2012a337efa3d77b6b3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 7, 2026.

Transparency log

Release history Release notifications | RSS feed

0.10.0

2 release files

0.9.5

2 release files

0.9.4

2 release files

0.9.3

2 release files

0.9.2

2 release files

This release

0.9.1 This release

2 release files

0.9.0

2 release files

0.8.4

2 release files

0.8.3

2 release files

0.8.2

2 release files

0.8.1

2 release files

0.8.0

2 release files

0.7.8

2 release files

0.7.6

2 release files

0.7.5

2 release files

0.7.4

2 release files

0.7.3

2 release files

0.7.2

2 release files

0.7.1

2 release files

0.7.0

2 release files

0.6.0

2 release files

0.5.6

2 release files

0.5.4

2 release files

0.5.3

2 release files

0.5.2

2 release files

0.5.1

2 release files

0.5.0

2 release files

0.4.0

2 release files

0.3.0

2 release files

0.2.3

2 release files

0.2.2

2 release files

0.2.1

2 release files

0.2.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page