Delete producerless tool capabilities

This commit is contained in:
Meta Vens 2026-08-23 12:40:11 +02:00
commit beb9fd32a9
5 changed files with 3 additions and 98 deletions

View file

@ -108,7 +108,6 @@ use epiphany_openai_adapter::EpiphanyOpenAiModelReceipt;
use epiphany_openai_adapter::EpiphanyOpenAiModelRequest;
use epiphany_openai_adapter::EpiphanyOpenAiStreamEvent;
use epiphany_openai_adapter::EpiphanyOpenAiStreamPayload;
use epiphany_tool_adapter::EpiphanyToolCapability;
use epiphany_tool_adapter::EpiphanyToolInvocationIntent;
use epiphany_tool_adapter::EpiphanyToolInvocationReceipt;
use epiphany_tool_adapter::TOOL_ADAPTER_INVOCATION_INTENT_SCHEMA_ID;
@ -151,7 +150,6 @@ pub const MODEL_ADAPTER_STATUS_TYPE: &str = "epiphany.model_adapter_status.v0";
pub const MODEL_REQUEST_TYPE: &str = "epiphany.model_request.v0";
pub const MODEL_STREAM_EVENT_TYPE: &str = "epiphany.model_stream_event.v0";
pub const MODEL_RECEIPT_TYPE: &str = "epiphany.model_receipt.v0";
pub const TOOL_CAPABILITY_TYPE: &str = "epiphany.tool_capability.v0";
pub const TOOL_INVOCATION_INTENT_TYPE: &str = "epiphany.tool_invocation_intent.v0";
pub const TOOL_INVOCATION_RECEIPT_TYPE: &str = "epiphany.tool_invocation_receipt.v0";
pub const RUNTIME_IDENTITY_KEY: &str = "self";
@ -183,7 +181,6 @@ pub const MODEL_ADAPTER_STATUS_SCHEMA_VERSION: &str = "epiphany.model_adapter_st
pub const MODEL_REQUEST_SCHEMA_VERSION: &str = "epiphany.model_request.v0";
pub const MODEL_STREAM_EVENT_SCHEMA_VERSION: &str = "epiphany.model_stream_event.v0";
pub const MODEL_RECEIPT_SCHEMA_VERSION: &str = "epiphany.model_receipt.v0";
pub const TOOL_CAPABILITY_SCHEMA_VERSION: &str = "epiphany.tool_capability.v0";
pub const TOOL_INVOCATION_INTENT_SCHEMA_VERSION: &str = "epiphany.tool_invocation_intent.v0";
pub const TOOL_INVOCATION_RECEIPT_SCHEMA_VERSION: &str = "epiphany.tool_invocation_receipt.v0";
pub const CULTNET_SCHEMA_INDEX_RELATIVE: &str = "schemas/cultnet/index.json";
@ -1154,7 +1151,6 @@ pub fn runtime_spine_cache(store_path: impl AsRef<Path>) -> Result<CultCache> {
cache.register_entry_type::<crate::PersonaConversationExecutionReceipt>()?;
cache.register_entry_type::<crate::PersonaEffectExecutionIntent>()?;
cache.register_entry_type::<crate::PersonaConversationStoreRetirementReceipt>()?;
cache.register_entry_type::<EpiphanyToolCapability>()?;
cache.register_entry_type::<EpiphanyToolInvocationIntent>()?;
cache.register_entry_type::<EpiphanyToolInvocationReceipt>()?;
cache.add_generic_backing_store(backing_store);
@ -13780,17 +13776,6 @@ fn epiphany_mutation_contracts() -> Vec<CultNetDocumentMutationContract> {
"Terminal model receipts carry provider response id, usage, and transport evidence.",
],
),
mutation_contract(
TOOL_CAPABILITY_TYPE,
TOOL_CAPABILITY_SCHEMA_VERSION,
vec![CultNetDocumentOperation::Snapshot],
CultNetMutationAuthority::ReadOnly,
vec![],
vec![],
vec![
"Tool capability documents describe adapter-discovered tools without making raw MCP discovery JSON authoritative.",
],
),
mutation_contract(
TOOL_INVOCATION_INTENT_TYPE,
TOOL_INVOCATION_INTENT_SCHEMA_VERSION,

View file

@ -1,6 +1,5 @@
use cultcache_rs::DatabaseEntry;
pub const TOOL_ADAPTER_CAPABILITY_SCHEMA_ID: &str = "epiphany.tool_capability.v0";
pub const TOOL_ADAPTER_INVOCATION_INTENT_SCHEMA_ID: &str = "epiphany.tool_invocation_intent.v0";
pub const TOOL_ADAPTER_INVOCATION_RECEIPT_SCHEMA_ID: &str = "epiphany.tool_invocation_receipt.v0";
pub const EPIPHANY_TOOL_RUNTIME_ADAPTER_ID: &str = "epiphany-tools";
@ -34,47 +33,6 @@ pub fn receipt_output_for_model(
.to_string()
}
#[derive(Debug, Clone, PartialEq, Eq, DatabaseEntry)]
#[cultcache(
type = "epiphany.tool_capability.v0",
schema = "EpiphanyToolCapability"
)]
pub struct EpiphanyToolCapability {
#[cultcache(key = 0)]
pub schema_id: String,
#[cultcache(key = 1)]
pub capability_id: String,
#[cultcache(key = 2)]
pub adapter: String,
#[cultcache(key = 3)]
pub server: String,
#[cultcache(key = 4)]
pub tool_name: String,
#[cultcache(key = 5, default)]
pub description: Option<String>,
#[cultcache(key = 6, default)]
pub input_schema_json: Option<String>,
}
impl EpiphanyToolCapability {
pub fn new(
capability_id: impl Into<String>,
adapter: impl Into<String>,
server: impl Into<String>,
tool_name: impl Into<String>,
) -> Self {
Self {
schema_id: TOOL_ADAPTER_CAPABILITY_SCHEMA_ID.to_string(),
capability_id: capability_id.into(),
adapter: adapter.into(),
server: server.into(),
tool_name: tool_name.into(),
description: None,
input_schema_json: None,
}
}
}
#[derive(Debug, Clone, PartialEq, Eq, DatabaseEntry)]
#[cultcache(
type = "epiphany.tool_invocation_intent.v0",

View file

@ -1,8 +1,8 @@
use anyhow::{Context, Result, anyhow};
use epiphany_tool_adapter::{
EPIPHANY_TOOL_RUNTIME_ADAPTER_ID, EpiphanyToolInvocationIntent, EpiphanyToolInvocationReceipt,
TOOL_ADAPTER_CAPABILITY_SCHEMA_ID, TOOL_ADAPTER_INVOCATION_INTENT_SCHEMA_ID,
TOOL_ADAPTER_INVOCATION_RECEIPT_SCHEMA_ID, tool_invocation_intent_key,
TOOL_ADAPTER_INVOCATION_INTENT_SCHEMA_ID, TOOL_ADAPTER_INVOCATION_RECEIPT_SCHEMA_ID,
tool_invocation_intent_key,
};
use epiphany_tool_mcp_runtime::{
McpRuntimeConfig, current_utc_timestamp, execute_epiphany_public, execute_epiphany_source,
@ -236,10 +236,6 @@ fn smoke() -> SmokeSummary {
}
fn schemas() -> BTreeMap<String, String> {
BTreeMap::from([
(
"capability".into(),
TOOL_ADAPTER_CAPABILITY_SCHEMA_ID.into(),
),
(
"intent".into(),
TOOL_ADAPTER_INVOCATION_INTENT_SCHEMA_ID.into(),
@ -406,12 +402,7 @@ mod tests {
private_state_exposed: false,
},
)?;
let grant = epiphany_core::heartbeat_issue_resident_self_grant(
&resident_store,
"schedule-state-tool",
"action-state-tool",
2,
)?
let grant = epiphany_core::issue_resident_self_grant(&resident_store, 2)?
.expect("grant");
let intent = EpiphanyToolInvocationIntent::new(
"native-state-read",

View file

@ -1,18 +0,0 @@
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://gamecult.dev/epiphany/cultnet/epiphany.tool-capability.schema.json",
"title": "Epiphany Tool Capability",
"description": "Typed capability advertised by an Epiphany tool adapter. MCP discovery JSON may be the source, but this document is the inspectable Epiphany-facing capability record.",
"type": "object",
"required": ["schema_id", "capability_id", "adapter", "server", "tool_name"],
"properties": {
"schema_id": { "const": "epiphany.tool_capability.v0" },
"capability_id": { "type": "string" },
"adapter": { "type": "string" },
"server": { "type": "string" },
"tool_name": { "type": "string" },
"description": { "type": ["string", "null"] },
"input_schema_json": { "type": ["string", "null"] }
},
"additionalProperties": false
}

View file

@ -144,17 +144,6 @@
"title": "Epiphany Model Receipt",
"path": "epiphany.model-receipt.schema.json"
},
{
"schemaId": "https://gamecult.dev/epiphany/cultnet/epiphany.tool-capability.schema.json",
"kind": "document_payload",
"wireContracts": [
"cultnet.schema.v0"
],
"schemaVersion": "epiphany.tool_capability.v0",
"documentType": "epiphany.tool_capability.v0",
"title": "Epiphany Tool Capability",
"path": "epiphany.tool-capability.schema.json"
},
{
"schemaId": "https://gamecult.dev/epiphany/cultnet/epiphany.tool-invocation-intent.schema.json",
"kind": "document_payload",