Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.pelion.dev/llms.txt

Use this file to discover all available pages before exploring further.

Schemas are locked. Additive changes only, under explicit version bumps.
Every message the protocol touches uses one of these Pydantic v2 types. Frozen once constructed. Strict validation. Canonical JSON uses camelCase, Python attributes are snake_case via alias_generator=to_camel.

Question

The off-chain canonical question format. Spec §4.2.
FieldTypeNotes
versionstring, Literal “0.1”Schema version. Bumps on any breaking change.
questionId0x-prefixed 32-byte hexDeterministic identifier, typically sha256(canonical_params). Validated.
requester0x-prefixed 20-byte hexAddress of the requesting contract or EOA on Base. Validated.
textstringNatural-language question text. Human readable.
resolutionCriteriastringExplicit criteria for YES, NO, or UNRESOLVABLE. The rubric miners apply.
resolutionTimeint (unix seconds)Earliest time at which the question is eligible for resolution.
expirationTimeint (unix seconds)After this, the requester may cancel if no verdict has finalized. Must be ≥ resolutionTime.
evidencePolicyEvidencePolicyRules bounding admissible evidence.
subnetRoutinglist of intBittensor netuids the question is routed to. Order not significant. On-chain this is encoded as a uint256 bitmap.
rewarddecimal stringUSDC smallest-unit reward. String to avoid JS/JSON bigint precision loss.
bondAmountdecimal stringUSDC smallest-unit requester bond. String.
submittedAtint (unix seconds)When the adapter accepted the submission on-chain.

EvidencePolicy

Nested in Question. Bounds what evidence a miner may cite.
FieldTypeNotes
allowedSourceCategorieslist of stringFor example, “government_official”, “major_news_outlets”.
allowedDomainslist of stringWhitelisted domains miners may cite as evidence.
maxAgeHoursint, ≥ 0Maximum age of evidence in hours, measured from resolutionTime.
minSourceCountint, ≥ 1Minimum number of independent sources required to support a verdict.

Verdict

The canonical verdict format. Spec §4.2.
FieldTypeNotes
versionstring, Literal “0.1”Schema version.
questionId0x-prefixed 32-byte hexMatches the originating Question.
outcomesigned intSee Outcome constants below. UNRESOLVABLE = -1, NO = 0, YES = 1, multi-outcome ≥ 2.
outcomeLabelnon-empty stringHuman-readable label. “YES”, “NO”, “UNRESOLVABLE”, or enumerated outcome name.
confidenceint, 0 to 10000Consensus confidence in basis points.
evidenceEvidenceNested evidence bundle.
reasoningReasoningPer-miner provenance plus the consensus rationale.
subnetMetadataSubnetMetadataBittensor-side metadata (subnet id, block height, validator set).
validatorSignatureshex stringThreshold signature or aggregated signatures from subnet validators. Format is subnet-specific.
timestampint (unix seconds)When the verdict bundle was assembled.

Evidence and EvidenceSource

Field (on Evidence)TypeNotes
sourceslist of EvidenceSourceEvidence sources consulted. Order not significant.
Field (on EvidenceSource)TypeNotes
urlstringCanonical URL of the source document.
contentHashalgorithm-prefixed hash”sha256:” + hex digest of retrieved content. Validated to have the prefix.
retrievedAtint (unix seconds)When the miner fetched the content.
relevantExcerptstringShort excerpt directly supporting the verdict.

Reasoning and MinerProvenance

Field (on Reasoning)TypeNotes
minerProvenancelist of MinerProvenancePer-miner verdicts and reasoning that fed into the consensus.
consensusRationalestringSummary of how miner outputs were combined.
Field (on MinerProvenance)TypeNotes
minerHotkeyss58 or sentinel stringBittensor hotkey, or a sentinel for non-subnet participants (frontier council uses “frontier-council:provider:model”).
individualVerdictsigned intThe miner’s individual outcome. May differ from consensus.
individualConfidenceint, 0 to 10000Miner-reported confidence in basis points.
reasoningTextstringThe miner’s natural-language reasoning.

SubnetMetadata

FieldTypeNotes
subnetIdint, ≥ 0Bittensor netuid. Sentinel value 0 for the synthetic frontier-model council.
blockHeightint, ≥ 0Subtensor block height at which validator consensus was taken.
validatorSetHashhex stringHash of the validator set active at blockHeight. Enables replayability.
weightedValidatorConsensusstringOpaque subnet-native representation of the weighted consensus at blockHeight.

Outcome

Sentinel integer values for the outcome field across Verdict, MinerProvenance, and PelionSynapse. Not an enum (enumerated markets require values outside the closed set).
NameValueNotes
UNRESOLVABLE-1Genuinely inconclusive council. First-class outcome, not an error.
NO0Binary NO.
YES1Binary YES.
(enumerated)≥ 2Multi-outcome markets use values at or above 2.

PelionSynapse

Bittensor wire envelope. Subclass of bt.Synapse. Lives in pelion.schemas.synapse and requires the bittensor extra. Inputs (validator populates, miner reads).
FieldType
question_idstring
textstring
resolution_criteriastring
resolution_timeint (unix seconds)
evidence_policyEvidencePolicy
deadlineint (unix seconds)
Outputs (miner populates, validator reads).
FieldType
outcomeoptional int
outcome_labeloptional string
confidenceoptional int
evidenceoptional Evidence
reasoning_textoptional string
Input fields are included in the Synapse request hash. Changes to input field names or types are wire-breaking and require coordinated miner, validator, and router updates.

Post-Task-1 spec amendments

Four ambiguities in the original spec were resolved and documented. They apply to all schema usage. subnet_routing encoding. Canonical off-chain JSON uses list[int] matching spec §4.2. On-chain, PelionAdapter.sol’s QuestionParams.subnetRouting is a uint256 bitmap. Bit i is set iff i is in subnet_routing. Caps at 256 netuids. evidence_hash and reasoning_hash. The spec’s Solidity Verdict struct has these as bytes32. The canonical off-chain Verdict does not carry them. Instead, they are computed at the router-to-adapter boundary as sha256(canonical_json_bytes(evidence)) and sha256(canonical_json_bytes(reasoning)). Canonical JSON uses model_dump_json(by_alias=True) with compact separators. This matches IPFS CIDv0 convention. The 32-byte digest is exactly the content-identifier portion of Qm<base58(digest)>. UNRESOLVABLE sentinel value. -1. Documented on the Outcome class. callback_contract and callback_selector. Adapter-layer fields only. Not on canonical off-chain Question. The miner, validator, and router never see them. The authoritative engineering reference lives at pelion/schemas/README.md in the repository.