Skip to main content
Glama
pytheum

Pytheum MCP

Official
by pytheum

pytheum-mcp

MCP server for the pytheum prediction-market context API.

On PyPI as pytheum-mcp. Source: github.com/pytheum/pytheum-mcp. Docs: github.com/pytheum/pytheum-doc.

Wraps the four public endpoints on api.pytheum.com as MCP tools so AI agents (Claude Desktop, Cursor, anything that speaks MCP over stdio) can ask "which markets does this news article move?" without writing their own retrieval layer.

Install

Two install paths — both run the same Python code. Pick whichever your MCP client makes easier:

# no install needed — npx runs it
npx -y @pytheum/mcp

Claude Desktop ships a Node.js runtime but not Python, so npx is the path of least resistance there. The npm package is a small shim that runs uvx pytheum-mcp under the hood; uv is still required (see the npm README for the install one-liner).

Via PyPI (Python-native)

uvx pytheum-mcp                # one-shot
uv tool install pytheum-mcp    # permanent

Requires Python 3.11+ and uv.

Configure

Claude Desktop

Edit ~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows):

{
  "mcpServers": {
    "pytheum": {
      "command": "npx",
      "args": ["-y", "@pytheum/mcp"],
      "env": {
        "PYTHEUM_API_BASE": "https://api.pytheum.com"
      }
    }
  }
}

Restart Claude Desktop. The hammer icon in the composer should list pytheum's tools.

Cursor / Windsurf / others

Same config under ~/.cursor/mcp.json (or the client's equivalent). If you already have uv on PATH, you can swap npx -y @pytheum/mcp for uvx pytheum-mcp to skip the Node shim entirely:

{
  "mcpServers": {
    "pytheum": {
      "command": "uvx",
      "args": ["pytheum-mcp"],
      "env": {
        "PYTHEUM_API_BASE": "https://api.pytheum.com"
      }
    }
  }
}

Tools

Tool

Endpoint

Description

t_find_markets(query, limit?, group_by?)

GET /v1/markets/relevant-to

Find markets matching free-text

t_market_context(market_ref, limit?)

GET /v1/markets/{ref}/context

Events paired with a market

t_bundle_context(bundle_ref, limit?)

GET /v1/bundles/{ref}/context

Events paired with any market in a bundle

t_event_related_markets(event_id, limit?)

GET /v1/events/{id}/related-markets

Markets related to a firehose event

Configuration

Env var

Default

Purpose

PYTHEUM_API_BASE

https://api.pytheum.com

Override to hit staging or a local stub

Reference

Endpoint schemas, response shapes, errors, and rate limits live in pytheum/pytheum-doc. The machine-readable OpenAPI spec is at openapi.yaml.

License

MIT

Available Tools

4 tools
t_bundle_contextC

Events paired with any market inside a bundle, deduplicated by event_id.

ParametersJSON Schema
NameRequiredDescriptionDefault
bundle_refYes
limitNo

TDQS

C2.7/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations provided, so description must disclose behavior. It mentions deduplication but does not state read-only nature, authorization needs, or error handling for invalid bundle_ref.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Single, efficient sentence that conveys core function and a key detail (deduplication). No unnecessary words.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the lack of output schema and annotations, the description is too brief. It does not clarify the nature of returned events, ordering, or how to interpret results relative to sibling tools.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters1/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 0% and description adds no meaning to the parameters (bundle_ref and limit). The description does not explain what bundle_ref expects or how limit affects results.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

Description clearly states the tool returns events paired with markets in a bundle, with deduplication by event_id. It distinguishes from siblings like t_find_markets and t_market_context by focusing on events from a bundle.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance on when to use this tool versus alternatives like t_event_related_markets. Lacks context on prerequisites or typical use cases.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

t_find_marketsC

Find prediction markets matching a free-form text query (article body / news headline / question).

ParametersJSON Schema
NameRequiredDescriptionDefault
queryYes
limitNo
group_byNo

TDQS

C2.6/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations are not provided, so the description must disclose behavioral traits. It only states the basic function and does not mention aspects like whether results are ranked, paginated, or if there are rate limits. The agent is left uninformed about important behaviors beyond the surface-level purpose.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, well-structured sentence that front-loads the core action. It is concise with no wasted words. However, it achieves conciseness at the cost of omitting necessary details like parameter explanations and usage scenarios.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the lack of output schema and 0% parameter description coverage, the description is incomplete. It does not explain what the tool returns (e.g., market IDs, details) or how the parameters like 'limit' and 'group_by' affect results. More context is needed for an agent to use the tool correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters1/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, meaning the schema lacks parameter descriptions. The description only mentions the 'query' parameter implicitly via examples (article body, news headline) but does not explain 'limit' or 'group_by'. No additional semantics are added beyond the schema's bare data types.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose: 'Find prediction markets matching a free-form text query.' It also provides examples of valid queries (article body, news headline, question), making the intent specific. However, it does not distinguish this tool from sibling tools like t_event_related_markets or t_market_context, so purpose could be clearer.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

There is no explicit guidance on when to use this tool versus alternatives. While the query type is described, there is no mention of prerequisites, constraints, or cases where this tool should not be used. The description only implies usage for text queries but offers no comparative context with siblings.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

t_market_contextC

Events (news/social/macro) paired with a specific market. market_ref accepts venue-prefixed id, slug, or URL.

ParametersJSON Schema
NameRequiredDescriptionDefault
market_refYes
limitNo

TDQS

C2.7/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations exist; the description adds minimal behavioral info (accepted formats for market_ref) but omits details like pagination, sorting, rate limits, or whether events are live. Mutation/read status is unclear.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two short sentences, no wasted words. Purpose and a key parameter hint are front-loaded. Could be more structured but efficient.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given no output schema and simple parameters, the description lacks details on event ordering, completeness criteria (e.g., time range), and error cases. Incomplete for confident invocation.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 0%. Description clarifies market_ref accepts venue-prefixed id, slug, or URL, adding value over schema name, but does not describe 'limit' or default behavior.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool returns events (news/social/macro) for a specific market, with a resource 'market_ref'. It differentiates from siblings like t_event_related_markets (which likely does the inverse) and t_find_markets (general search), though not explicitly.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance on when to use this tool over siblings t_bundle_context or t_event_related_markets. It only describes accepted formats for market_ref, not usage context.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

  1. 4 tool updatesv0.1.0
    • First observedt_bundle_context
    • First observedt_event_related_markets
    • First observedt_find_markets
    • First observedt_market_context

TDQS

B3.3/5.0

Scored across 4 tools

Disambiguation5/5

Each tool targets a distinct purpose: bundle context, event-related markets, free-text search, and market context. No overlap in functionality.

Naming Consistency4/5

All tools use a consistent 't_' prefix and snake_case, but not all follow a strict verb_noun pattern (e.g., 'bundle_context' is noun-like). Still highly uniform.

Tool Count5/5

Four tools is an ideal size for this domain—each tool serves a clear, non-redundant purpose without being too few or too many.

Completeness5/5

The tool set covers the core operations for retrieving prediction market data: search, context, and event linking. No obvious gaps for a read-oriented server.

Related MCP Connectors