Skip to main content

otomata-mcp

Socle commun des serveurs MCP Otomata (Python / FastMCP). Tout-en-tools (pas de resource ni de prompt → tout accès est loggé), scopé par entreprise.

Le socle modélise l'intra-entreprise (1 org = X groupes, Y users). Le multi-entreprise (× Z) — résolution de l'org courante, platform_admin, marketplace de doctrines — reste dans l'orchestrateur (oto / madeleine), qui injecte un scope (tenant_id) à chaque appel. Le socle ne requête jamais sans scope → pas de fuite cross-org.

Modules

otomata_mcp/
  scope.py        # Scope + ScopeResolver (ConstantScope = Z1, CallableScope = ZN)
  identity.py     # current_identity() via resolver injecté (JWT en prod)
  content/        # instructions en base, servies EN TOOLS (readme_agent / list_instructions / get_instruction / set_instruction)
                  #   model · store (Protocol + InMemory) · validate (zéro nom) · schema (DDL) · tools
  run/            # start/stop : pile de runs en session state, corrélée run_id
  rbac/           # org_admin → group_admin → member, scopé (gate des tools)
  logging.py      # middleware run-aware (réutilise le schéma otomata-calllog + run_id)
  bootstrap.py    # build_server(...) compose tout

Ce que le consommateur fournit (injecté)

  • un ContentStore (OGIC : PostgREST/Supabase ; oto/madeleine : asyncpg) — SCHEMA_SQL fourni ;
  • un RoleStore (rôles scopés) ;
  • un ScopeResolver (ConstantScope("ogic") en Z=1, CallableScope(current_org) en Z=N) ;
  • un sink de logs (table tool_calls, cf. otomata-calllog) ;
  • l'auth (verifier JWT du provider) — le socle lit l'identité via un resolver injecté.

Exemple

from otomata_mcp import build_server, InMemoryContentStore, InMemoryRoleStore, ConstantScope
mcp = build_server("mon-mcp", content_store=..., role_store=..., scope_resolver=ConstantScope("acme"),
                   sink=my_sink, blocklist=["NomInterdit"])

example_demo.py montre tout (doctrines-tools loggées + corrélées run_id, RBAC, validation).

Dev

python -m venv .venv && . .venv/bin/activate
pip install -e ".[dev]"
pytest          # tests du socle
python example_demo.py

Distribution

Publié sur PyPI (pip install otomata-mcp), modèle otomata-calllog. Le contenu est du plumbing MCP générique — aucun secret ni donnée client.

Metadata

Release files for otomata-mcp 0.3.0

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

Source distribution (sdist)

Source distribution for otomata-mcp 0.3.0
File Size Uploaded Provenance Actions
otomata_mcp-0.3.0.tar.gz 14.4 kB Without provenance Details for otomata_mcp-0.3.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for otomata-mcp 0.3.0
File Interpreter ABI Platform Actions
otomata_mcp-0.3.0-py3-none-any.whl Python 3 none any Details for otomata_mcp-0.3.0-py3-none-any.whl

Total release size: 32.3 kB

Release files / otomata_mcp-0.3.0.tar.gz

Download URL otomata_mcp-0.3.0.tar.gz
Size 14.4 kB
Tags Source
SHA-256 checksum
How to use checksums
86e7e7778452eb4749b8085a1cac7cfba84f48f95827d6d893bab2d600b4aac6
BLAKE2b-256 checksum
How to use checksums
acf34dd513356653bd8cc32d89aabc67ed91308189d1bb9f51c318ac3e919d3b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.14.4

Release files / otomata_mcp-0.3.0-py3-none-any.whl

Download URL otomata_mcp-0.3.0-py3-none-any.whl
Size 17.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
cd72ee4d6571df0399cb95e2af322cc4fbd3900fc91442e068e65bc767ac1dd2
BLAKE2b-256 checksum
How to use checksums
03664b1355e76b4f872aab65c85f72742260e3a22e6a6dfd00063188f633e888
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.14.4

Security for otomata-mcp 0.3.0

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.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

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