Greg647465374's picture
shorten the files
41c095f
{
"ast": {
"items": [
{
"use": {
"tree": {
"path": {
"ident": "rrust_kontekst_base",
"tree": {
"group": [
{
"ident": "get_mcp_tools_schema"
},
{
"ident": "invoke_mcp_tool"
},
{
"ident": "McpError"
}
]
}
}
}
}
},
{
"use": {
"tree": {
"path": {
"ident": "serde_json",
"tree": {
"ident": "json"
}
}
}
}
},
{
"use": {
"tree": {
"path": {
"ident": "std",
"tree": {
"path": {
"ident": "error",
"tree": {
"ident": "Error"
}
}
}
}
}
}
},
{
"mod": {
"content": [
{
"fn": {
"async": true,
"attrs": [
{
"meta": {
"list": {
"delimiter": "paren",
"path": {
"segments": [
{
"ident": "rrust_kontekst"
},
{
"ident": "mcp_component"
}
]
},
"tokens": [
{
"ident": "menu"
},
{
"punct": {
"op": "=",
"spacing": "alone"
}
},
{
"lit": "\"core\""
},
{
"punct": {
"op": ",",
"spacing": "alone"
}
},
{
"ident": "label"
},
{
"punct": {
"op": "=",
"spacing": "alone"
}
},
{
"lit": "\"Embedding Generator\""
},
{
"punct": {
"op": ",",
"spacing": "alone"
}
},
{
"ident": "emoji"
},
{
"punct": {
"op": "=",
"spacing": "alone"
}
},
{
"lit": "\"🔤\""
},
{
"punct": {
"op": ",",
"spacing": "alone"
}
},
{
"ident": "description"
},
{
"punct": {
"op": "=",
"spacing": "alone"
}
},
{
"lit": "\"Generate embeddings for text input\""
},
{
"punct": {
"op": ",",
"spacing": "alone"
}
},
{
"ident": "order"
},
{
"punct": {
"op": "=",
"spacing": "alone"
}
},
{
"lit": "1"
}
]
}
},
"style": "outer"
}
],
"ident": "embedding_component",
"inputs": [],
"output": {
"path": {
"segments": [
{
"arguments": {
"angle_bracketed": {
"args": [
{
"type": {
"path": {
"segments": [
{
"ident": "String"
}
]
}
}
},
{
"type": {
"path": {
"segments": [
{
"arguments": {
"angle_bracketed": {
"args": [
{
"type": {
"trait_object": {
"bounds": [
{
"trait": {
"path": {
"segments": [
{
"ident": "std"
},
{
"ident": "error"
},
{
"ident": "Error"
}
]
}
}
}
],
"dyn": true
}
}
}
]
}
},
"ident": "Box"
}
]
}
}
}
]
}
},
"ident": "Result"
}
]
}
},
"stmts": [
{
"expr": [
{
"call": {
"args": [
{
"method_call": {
"args": [],
"method": "to_string",
"receiver": {
"lit": {
"str": "\"Test component executed successfully\""
}
}
}
}
],
"func": {
"path": {
"segments": [
{
"ident": "Ok"
}
]
}
}
}
},
false
]
}
],
"vis": "pub"
}
}
],
"ident": "Comp1"
}
},
{
"mod": {
"content": [
{
"use": {
"tree": {
"path": {
"ident": "rrust_kontekst",
"tree": {
"ident": "mcp_component"
}
}
}
}
},
{
"fn": {
"async": true,
"attrs": [
{
"meta": {
"list": {
"delimiter": "paren",
"path": {
"segments": [
{
"ident": "mcp_component"
}
]
},
"tokens": [
{
"ident": "menu"
},
{
"punct": {
"op": "=",
"spacing": "alone"
}
},
{
"lit": "\"ai_models\""
},
{
"punct": {
"op": ",",
"spacing": "alone"
}
},
{
"ident": "label"
},
{
"punct": {
"op": "=",
"spacing": "alone"
}
},
{
"lit": "\"BERT Inference\""
},
{
"punct": {
"op": ",",
"spacing": "alone"
}
},
{
"ident": "emoji"
},
{
"punct": {
"op": "=",
"spacing": "alone"
}
},
{
"lit": "\"🤖\""
},
{
"punct": {
"op": ",",
"spacing": "alone"
}
},
{
"ident": "description"
},
{
"punct": {
"op": "=",
"spacing": "alone"
}
},
{
"lit": "\"Run BERT model inference on input text\""
},
{
"punct": {
"op": ",",
"spacing": "alone"
}
},
{
"ident": "tool_name"
},
{
"punct": {
"op": "=",
"spacing": "alone"
}
},
{
"lit": "\"bert_inference\""
},
{
"punct": {
"op": ",",
"spacing": "alone"
}
},
{
"ident": "visible"
},
{
"punct": {
"op": "=",
"spacing": "alone"
}
},
{
"ident": "true"
},
{
"punct": {
"op": ",",
"spacing": "alone"
}
},
{
"ident": "order"
},
{
"punct": {
"op": "=",
"spacing": "alone"
}
},
{
"lit": "2"
},
{
"punct": {
"op": ",",
"spacing": "alone"
}
},
{
"ident": "returns"
},
{
"punct": {
"op": "=",
"spacing": "alone"
}
},
{
"lit": "\"BERT model predictions and confidence scores\""
}
]
}
},
"style": "outer"
}
],
"ident": "bert_test_component",
"inputs": [],
"output": {
"path": {
"segments": [
{
"arguments": {
"angle_bracketed": {
"args": [
{
"type": {
"path": {
"segments": [
{
"ident": "String"
}
]
}
}
},
{
"type": {
"path": {
"segments": [
{
"arguments": {
"angle_bracketed": {
"args": [
{
"type": {
"trait_object": {
"bounds": [
{
"trait": {
"path": {
"segments": [
{
"ident": "std"
},
{
"ident": "error"
},
{
"ident": "Error"
}
]
}
}
}
],
"dyn": true
}
}
}
]
}
},
"ident": "Box"
}
]
}
}
}
]
}
},
"ident": "Result"
}
]
}
},
"stmts": [
{
"expr": [
{
"call": {
"args": [
{
"method_call": {
"args": [],
"method": "to_string",
"receiver": {
"lit": {
"str": "\"Test component executed successfully\""
}
}
}
}
],
"func": {
"path": {
"segments": [
{
"ident": "Ok"
}
]
}
}
}
},
false
]
}
],
"vis": "pub"
}
}
],
"ident": "Comp2"
}
},
{
"mod": {
"content": [
{
"use": {
"tree": {
"path": {
"ident": "rrust_kontekst",
"tree": {
"ident": "mcp_component"
}
}
}
}
},
{
"fn": {
"async": true,
"attrs": [
{
"meta": {
"list": {
"delimiter": "paren",
"path": {
"segments": [
{
"ident": "mcp_component"
}
]
},
"tokens": [
{
"ident": "menu"
},
{
"punct": {
"op": "=",
"spacing": "alone"
}
},
{
"lit": "\"experimental\""
},
{
"punct": {
"op": ",",
"spacing": "alone"
}
},
{
"ident": "label"
},
{
"punct": {
"op": "=",
"spacing": "alone"
}
},
{
"lit": "\"Experimental Feature\""
},
{
"punct": {
"op": ",",
"spacing": "alone"
}
},
{
"ident": "emoji"
},
{
"punct": {
"op": "=",
"spacing": "alone"
}
},
{
"lit": "\"⚗️\""
},
{
"punct": {
"op": ",",
"spacing": "alone"
}
},
{
"ident": "description"
},
{
"punct": {
"op": "=",
"spacing": "alone"
}
},
{
"lit": "\"Experimental feature under development\""
},
{
"punct": {
"op": ",",
"spacing": "alone"
}
},
{
"ident": "visible"
},
{
"punct": {
"op": "=",
"spacing": "alone"
}
},
{
"ident": "false"
},
{
"punct": {
"op": ",",
"spacing": "alone"
}
},
{
"ident": "mcp"
},
{
"punct": {
"op": "=",
"spacing": "alone"
}
},
{
"ident": "false"
}
]
}
},
"style": "outer"
}
],
"ident": "experimental_component",
"inputs": [],
"output": {
"path": {
"segments": [
{
"arguments": {
"angle_bracketed": {
"args": [
{
"type": {
"path": {
"segments": [
{
"ident": "String"
}
]
}
}
},
{
"type": {
"path": {
"segments": [
{
"arguments": {
"angle_bracketed": {
"args": [
{
"type": {
"trait_object": {
"bounds": [
{
"trait": {
"path": {
"segments": [
{
"ident": "std"
},
{
"ident": "error"
},
{
"ident": "Error"
}
]
}
}
}
],
"dyn": true
}
}
}
]
}
},
"ident": "Box"
}
]
}
}
}
]
}
},
"ident": "Result"
}
]
}
},
"stmts": [
{
"expr": [
{
"call": {
"args": [
{
"method_call": {
"args": [],
"method": "to_string",
"receiver": {
"lit": {
"str": "\"Test component executed successfully\""
}
}
}
}
],
"func": {
"path": {
"segments": [
{
"ident": "Ok"
}
]
}
}
}
},
false
]
}
],
"vis": "pub"
}
}
],
"ident": "Comp4"
}
},
{
"mod": {
"content": [
{
"use": {
"tree": {
"path": {
"ident": "rrust_kontekst",
"tree": {
"ident": "mcp_component"
}
}
}
}
},
{
"fn": {
"async": true,
"attrs": [
{
"meta": {
"list": {
"delimiter": "paren",
"path": {
"segments": [
{
"ident": "mcp_component"
}
]
},
"tokens": [
{
"ident": "menu"
},
{
"punct": {
"op": "=",
"spacing": "alone"
}
},
{
"lit": "\"core\""
},
{
"punct": {
"op": ",",
"spacing": "alone"
}
},
{
"ident": "label"
},
{
"punct": {
"op": "=",
"spacing": "alone"
}
},
{
"lit": "\"Text Processor\""
},
{
"punct": {
"op": ",",
"spacing": "alone"
}
},
{
"ident": "emoji"
},
{
"punct": {
"op": "=",
"spacing": "alone"
}
},
{
"lit": "\"📝\""
},
{
"punct": {
"op": ",",
"spacing": "alone"
}
},
{
"ident": "description"
},
{
"punct": {
"op": "=",
"spacing": "alone"
}
},
{
"lit": "\"Process and analyze text content\""
},
{
"punct": {
"op": ",",
"spacing": "alone"
}
},
{
"ident": "order"
},
{
"punct": {
"op": "=",
"spacing": "alone"
}
},
{
"punct": {
"op": "-",
"spacing": "alone"
}
},
{
"lit": "1"
}
]
}
},
"style": "outer"
}
],
"ident": "text_processor_component",
"inputs": [],
"output": {
"path": {
"segments": [
{
"arguments": {
"angle_bracketed": {
"args": [
{
"type": {
"path": {
"segments": [
{
"ident": "String"
}
]
}
}
},
{
"type": {
"path": {
"segments": [
{
"arguments": {
"angle_bracketed": {
"args": [
{
"type": {
"trait_object": {
"bounds": [
{
"trait": {
"path": {
"segments": [
{
"ident": "std"
},
{
"ident": "error"
},
{
"ident": "Error"
}
]
}
}
}
],
"dyn": true
}
}
}
]
}
},
"ident": "Box"
}
]
}
}
}
]
}
},
"ident": "Result"
}
]
}
},
"stmts": [
{
"expr": [
{
"call": {
"args": [
{
"method_call": {
"args": [],
"method": "to_string",
"receiver": {
"lit": {
"str": "\"Test component executed successfully\""
}
}
}
}
],
"func": {
"path": {
"segments": [
{
"ident": "Ok"
}
]
}
}
}
},
false
]
}
],
"vis": "pub"
}
}
],
"ident": "Comp5"
}
},
{
"fn": {
"attrs": [
{
"meta": {
"name_value": {
"path": {
"segments": [
{
"ident": "doc"
}
]
},
"value": {
"lit": {
"str": "\" Initialize all MCP components\""
}
}
}
},
"style": "outer"
}
],
"ident": "initialize_mcp_system",
"inputs": [],
"output": null,
"stmts": [
{
"macro": {
"delimiter": "paren",
"path": {
"segments": [
{
"ident": "println"
}
]
},
"semi_token": true,
"tokens": [
{
"lit": "\"Initializing MCP system...\""
}
]
}
}
],
"vis": "pub"
}
},
{
"fn": {
"async": true,
"attrs": [
{
"meta": {
"name_value": {
"path": {
"segments": [
{
"ident": "doc"
}
]
},
"value": {
"lit": {
"str": "\" Get available tools for a specific menu\""
}
}
}
},
"style": "outer"
}
],
"ident": "get_tools_for_menu",
"inputs": [
{
"typed": {
"pat": {
"ident": {
"ident": "menu_type"
}
},
"ty": {
"reference": {
"elem": {
"path": {
"segments": [
{
"ident": "str"
}
]
}
}
}
}
}
}
],
"output": {
"path": {
"segments": [
{
"arguments": {
"angle_bracketed": {
"args": [
{
"type": {
"path": {
"segments": [
{
"ident": "serde_json"
},
{
"ident": "Value"
}
]
}
}
},
{
"type": {
"path": {
"segments": [
{
"ident": "McpError"
}
]
}
}
}
]
}
},
"ident": "Result"
}
]
}
},
"stmts": [
{
"expr": [
{
"call": {
"args": [
{
"path": {
"segments": [
{
"ident": "menu_type"
}
]
}
}
],
"func": {
"path": {
"segments": [
{
"ident": "get_mcp_tools_schema"
}
]
}
}
}
},
false
]
}
],
"vis": "pub"
}
},
{
"fn": {
"async": true,
"attrs": [
{
"meta": {
"name_value": {
"path": {
"segments": [
{
"ident": "doc"
}
]
},
"value": {
"lit": {
"str": "\" Example of manual tool invocation\""
}
}
}
},
"style": "outer"
}
],
"ident": "example_tool_usage",
"inputs": [],
"output": {
"path": {
"segments": [
{
"arguments": {
"angle_bracketed": {
"args": [
{
"type": {
"tuple": {
"elems": []
}
}
},
{
"type": {
"path": {
"segments": [
{
"arguments": {
"angle_bracketed": {
"args": [
{
"type": {
"trait_object": {
"bounds": [
{
"trait": {
"path": {
"segments": [
{
"ident": "Error"
}
]
}
}
}
],
"dyn": true
}
}
}
]
}
},
"ident": "Box"
}
]
}
}
}
]
}
},
"ident": "Result"
}
]
}
},
"stmts": [
{
"macro": {
"delimiter": "paren",
"path": {
"segments": [
{
"ident": "println"
}
]
},
"semi_token": true,
"tokens": [
{
"lit": "\"=== MCP System Demo ===\""
}
]
}
},
{
"expr": [
{
"call": {
"args": [],
"func": {
"path": {
"segments": [
{
"ident": "initialize_mcp_system"
}
]
}
}
}
},
true
]
},
{
"expr": [
{
"match": {
"arms": [
{
"body": {
"block": {
"stmts": [
{
"macro": {
"delimiter": "paren",
"path": {
"segments": [
{
"ident": "println"
}
]
},
"semi_token": true,
"tokens": [
{
"lit": "\"Available core tools: {:?}\""
},
{
"punct": {
"op": ",",
"spacing": "alone"
}
},
{
"ident": "serde_json"
},
{
"punct": {
"op": ":",
"spacing": "joint"
}
},
{
"punct": {
"op": ":",
"spacing": "alone"
}
},
{
"ident": "to_string_pretty"
},
{
"group": {
"delimiter": "parenthesis",
"stream": [
{
"punct": {
"op": "&",
"spacing": "alone"
}
},
{
"ident": "schema"
}
]
}
},
{
"punct": {
"op": "?",
"spacing": "alone"
}
}
]
}
}
]
}
},
"pat": {
"tuple_struct": {
"elems": [
{
"ident": {
"ident": "schema"
}
}
],
"path": {
"segments": [
{
"ident": "Ok"
}
]
}
}
}
},
{
"body": {
"block": {
"stmts": [
{
"macro": {
"delimiter": "paren",
"path": {
"segments": [
{
"ident": "println"
}
]
},
"semi_token": true,
"tokens": [
{
"lit": "\"Error getting tools: {}\""
},
{
"punct": {
"op": ",",
"spacing": "alone"
}
},
{
"ident": "e"
}
]
}
}
]
}
},
"pat": {
"tuple_struct": {
"elems": [
{
"ident": {
"ident": "e"
}
}
],
"path": {
"segments": [
{
"ident": "Err"
}
]
}
}
}
}
],
"expr": {
"await": {
"base": {
"call": {
"args": [
{
"lit": {
"str": "\"core\""
}
}
],
"func": {
"path": {
"segments": [
{
"ident": "get_tools_for_menu"
}
]
}
}
}
}
}
}
}
},
false
]
},
{
"expr": [
{
"match": {
"arms": [
{
"body": {
"block": {
"stmts": [
{
"macro": {
"delimiter": "paren",
"path": {
"segments": [
{
"ident": "println"
}
]
},
"semi_token": true,
"tokens": [
{
"lit": "\"Tool result: {}\""
},
{
"punct": {
"op": ",",
"spacing": "alone"
}
},
{
"ident": "serde_json"
},
{
"punct": {
"op": ":",
"spacing": "joint"
}
},
{
"punct": {
"op": ":",
"spacing": "alone"
}
},
{
"ident": "to_string_pretty"
},
{
"group": {
"delimiter": "parenthesis",
"stream": [
{
"punct": {
"op": "&",
"spacing": "alone"
}
},
{
"ident": "result"
}
]
}
},
{
"punct": {
"op": "?",
"spacing": "alone"
}
}
]
}
}
]
}
},
"pat": {
"tuple_struct": {
"elems": [
{
"ident": {
"ident": "result"
}
}
],
"path": {
"segments": [
{
"ident": "Ok"
}
]
}
}
}
},
{
"body": {
"block": {
"stmts": [
{
"macro": {
"delimiter": "paren",
"path": {
"segments": [
{
"ident": "println"
}
]
},
"semi_token": true,
"tokens": [
{
"lit": "\"Tool invocation failed: {}\""
},
{
"punct": {
"op": ",",
"spacing": "alone"
}
},
{
"ident": "e"
}
]
}
}
]
}
},
"pat": {
"tuple_struct": {
"elems": [
{
"ident": {
"ident": "e"
}
}
],
"path": {
"segments": [
{
"ident": "Err"
}
]
}
}
}
}
],
"expr": {
"await": {
"base": {
"call": {
"args": [
{
"lit": {
"str": "\"embedding\""
}
},
{
"macro": {
"delimiter": "paren",
"path": {
"segments": [
{
"ident": "json"
}
]
},
"tokens": [
{
"group": {
"delimiter": "brace",
"stream": [
{
"lit": "\"text\""
},
{
"punct": {
"op": ":",
"spacing": "alone"
}
},
{
"lit": "\"Hello, world!\""
}
]
}
}
]
}
}
],
"func": {
"path": {
"segments": [
{
"ident": "invoke_mcp_tool"
}
]
}
}
}
}
}
}
}
},
false
]
},
{
"expr": [
{
"call": {
"args": [
{
"tuple": {
"elems": []
}
}
],
"func": {
"path": {
"segments": [
{
"ident": "Ok"
}
]
}
}
}
},
false
]
}
],
"vis": "pub"
}
},
{
"mod": {
"attrs": [
{
"meta": {
"list": {
"delimiter": "paren",
"path": {
"segments": [
{
"ident": "cfg"
}
]
},
"tokens": [
{
"ident": "test"
}
]
}
},
"style": "outer"
}
],
"content": [
{
"use": {
"tree": {
"path": {
"ident": "super",
"tree": "*"
}
}
}
},
{
"fn": {
"async": true,
"attrs": [
{
"meta": {
"path": {
"segments": [
{
"ident": "tokio"
},
{
"ident": "test"
}
]
}
},
"style": "outer"
}
],
"ident": "test_component_execution",
"inputs": [],
"output": null,
"stmts": [
{
"let": {
"init": {
"expr": {
"await": {
"base": {
"call": {
"args": [],
"func": {
"path": {
"segments": [
{
"ident": "embedding_component"
}
]
}
}
}
}
}
}
},
"pat": {
"ident": {
"ident": "result"
}
}
}
},
{
"macro": {
"delimiter": "paren",
"path": {
"segments": [
{
"ident": "assert"
}
]
},
"semi_token": true,
"tokens": [
{
"ident": "result"
},
{
"punct": {
"op": ".",
"spacing": "alone"
}
},
{
"ident": "is_ok"
},
{
"group": {
"delimiter": "parenthesis",
"stream": []
}
}
]
}
},
{
"let": {
"init": {
"expr": {
"await": {
"base": {
"call": {
"args": [],
"func": {
"path": {
"segments": [
{
"ident": "bert_test_component"
}
]
}
}
}
}
}
}
},
"pat": {
"ident": {
"ident": "result"
}
}
}
},
{
"macro": {
"delimiter": "paren",
"path": {
"segments": [
{
"ident": "assert"
}
]
},
"semi_token": true,
"tokens": [
{
"ident": "result"
},
{
"punct": {
"op": ".",
"spacing": "alone"
}
},
{
"ident": "is_ok"
},
{
"group": {
"delimiter": "parenthesis",
"stream": []
}
}
]
}
},
{
"let": {
"init": {
"expr": {
"method_call": {
"args": [],
"method": "unwrap",
"receiver": {
"path": {
"segments": [
{
"ident": "result"
}
]
}
}
}
}
},
"pat": {
"ident": {
"ident": "json_result"
}
}
}
},
{
"macro": {
"delimiter": "paren",
"path": {
"segments": [
{
"ident": "assert"
}
]
},
"semi_token": true,
"tokens": [
{
"ident": "json_result"
},
{
"punct": {
"op": ".",
"spacing": "alone"
}
},
{
"ident": "get"
},
{
"group": {
"delimiter": "parenthesis",
"stream": [
{
"lit": "\"predictions\""
}
]
}
},
{
"punct": {
"op": ".",
"spacing": "alone"
}
},
{
"ident": "is_some"
},
{
"group": {
"delimiter": "parenthesis",
"stream": []
}
}
]
}
}
]
}
},
{
"fn": {
"async": true,
"attrs": [
{
"meta": {
"path": {
"segments": [
{
"ident": "tokio"
},
{
"ident": "test"
}
]
}
},
"style": "outer"
}
],
"ident": "test_mcp_system_integration",
"inputs": [],
"output": null,
"stmts": [
{
"expr": [
{
"call": {
"args": [],
"func": {
"path": {
"segments": [
{
"ident": "initialize_mcp_system"
}
]
}
}
}
},
true
]
},
{
"let": {
"init": {
"expr": {
"await": {
"base": {
"call": {
"args": [
{
"lit": {
"str": "\"core\""
}
}
],
"func": {
"path": {
"segments": [
{
"ident": "get_tools_for_menu"
}
]
}
}
}
}
}
}
},
"pat": {
"ident": {
"ident": "schema"
}
}
}
},
{
"macro": {
"delimiter": "paren",
"path": {
"segments": [
{
"ident": "assert"
}
]
},
"semi_token": true,
"tokens": [
{
"ident": "schema"
},
{
"punct": {
"op": ".",
"spacing": "alone"
}
},
{
"ident": "is_ok"
},
{
"group": {
"delimiter": "parenthesis",
"stream": []
}
}
]
}
},
{
"let": {
"init": {
"expr": {
"call": {
"args": [],
"func": {
"path": {
"segments": [
{
"ident": "list_all_tools"
}
]
}
}
}
}
},
"pat": {
"ident": {
"ident": "tools"
}
}
}
},
{
"expr": [
{
"if": {
"cond": {
"let": {
"expr": {
"path": {
"segments": [
{
"ident": "tools"
}
]
}
},
"pat": {
"tuple_struct": {
"elems": [
{
"ident": {
"ident": "tool_list"
}
}
],
"path": {
"segments": [
{
"ident": "Ok"
}
]
}
}
}
}
},
"then_branch": [
{
"macro": {
"delimiter": "paren",
"path": {
"segments": [
{
"ident": "println"
}
]
},
"semi_token": true,
"tokens": [
{
"lit": "\"Registered tools: {:?}\""
},
{
"punct": {
"op": ",",
"spacing": "alone"
}
},
{
"ident": "tool_list"
}
]
}
}
]
}
},
false
]
}
]
}
},
{
"fn": {
"attrs": [
{
"meta": {
"path": {
"segments": [
{
"ident": "test"
}
]
}
},
"style": "outer"
}
],
"ident": "test_configuration_parsing",
"inputs": [],
"output": null,
"stmts": [
{
"macro": {
"delimiter": "paren",
"path": {
"segments": [
{
"ident": "assert"
}
]
},
"semi_token": true,
"tokens": [
{
"ident": "true"
}
]
}
}
]
}
}
],
"ident": "tests"
}
},
{
"use": {
"tree": {
"path": {
"ident": "crate",
"tree": {
"path": {
"ident": "extractor",
"tree": {
"path": {
"ident": "components",
"tree": {
"path": {
"ident": "example",
"tree": {
"group": [
{
"path": {
"ident": "Comp1",
"tree": {
"ident": "register_embedding_component"
}
}
},
{
"path": {
"ident": "Comp2",
"tree": {
"ident": "register_bert_test_component"
}
}
},
{
"path": {
"ident": "Comp4",
"tree": {
"ident": "register_experimental_component"
}
}
},
{
"path": {
"ident": "Comp5",
"tree": {
"ident": "register_text_processor_component"
}
}
}
]
}
}
}
}
}
}
}
}
}
}
},
{
"fn": {
"ident": "register_all_components",
"inputs": [],
"output": null,
"stmts": [
{
"expr": [
{
"call": {
"args": [],
"func": {
"path": {
"segments": [
{
"ident": "register_embedding_component"
}
]
}
}
}
},
true
]
},
{
"expr": [
{
"call": {
"args": [],
"func": {
"path": {
"segments": [
{
"ident": "register_bert_test_component"
}
]
}
}
}
},
true
]
},
{
"expr": [
{
"call": {
"args": [],
"func": {
"path": {
"segments": [
{
"ident": "register_experimental_component"
}
]
}
}
}
},
true
]
},
{
"expr": [
{
"call": {
"args": [],
"func": {
"path": {
"segments": [
{
"ident": "register_text_processor_component"
}
]
}
}
}
},
true
]
}
],
"vis": "pub"
}
}
]
},
"file_path": "src\\extractor\\components\\example.rs",
"summary": {
"emoji_counts_in_strings": {
"⚗": 1,
"️": 1,
"📝": 1,
"🔤": 1,
"🤖": 1
},
"string_literals": [
"\"core\"",
"\"Embedding Generator\"",
"\"🔤\"",
"\"Generate embeddings for text input\"",
"1",
"\"Test component executed successfully\"",
"\"ai_models\"",
"\"BERT Inference\"",
"\"🤖\"",
"\"Run BERT model inference on input text\"",
"\"bert_inference\"",
"2",
"\"BERT model predictions and confidence scores\"",
"\"Test component executed successfully\"",
"\"experimental\"",
"\"Experimental Feature\"",
"\"⚗️\"",
"\"Experimental feature under development\"",
"\"Test component executed successfully\"",
"\"core\"",
"\"Text Processor\"",
"\"📝\"",
"\"Process and analyze text content\"",
"1",
"\"Test component executed successfully\"",
"\" Initialize all MCP components\"",
"\"Initializing MCP system...\"",
"\" Get available tools for a specific menu\"",
"\" Example of manual tool invocation\"",
"\"=== MCP System Demo ===\"",
"\"Available core tools: {:?}\"",
"\"Error getting tools: {}\"",
"\"core\"",
"\"Tool result: {}\"",
"\"Tool invocation failed: {}\"",
"\"embedding\"",
"\"text\"",
"\"Hello, world!\"",
"\"predictions\"",
"\"core\"",
"\"Registered tools: {:?}\""
],
"top_level_nodes": 1,
"total_nodes": 795,
"type_counts": {
"angle_bracketed": 11,
"args": 34,
"arguments": 11,
"arms": 2,
"async": 8,
"attrs": 11,
"await": 5,
"base": 5,
"block": 4,
"body": 4,
"bounds": 5,
"call": 18,
"cond": 1,
"content": 5,
"delimiter": 26,
"dyn": 5,
"elem": 1,
"elems": 7,
"expr": 23,
"fn": 11,
"func": 18,
"group": 10,
"ident": 198,
"if": 1,
"init": 5,
"inputs": 11,
"items": 1,
"let": 6,
"list": 5,
"lit": 41,
"macro": 13,
"match": 2,
"meta": 11,
"method": 5,
"method_call": 5,
"mod": 5,
"name_value": 3,
"op": 64,
"output": 11,
"pat": 11,
"path": 89,
"punct": 64,
"receiver": 5,
"reference": 1,
"segments": 73,
"semi_token": 12,
"spacing": 64,
"stmts": 15,
"str": 10,
"stream": 8,
"style": 11,
"then_branch": 1,
"tokens": 18,
"trait": 5,
"trait_object": 5,
"tree": 24,
"tuple": 2,
"tuple_struct": 5,
"ty": 1,
"type": 17,
"typed": 1,
"use": 8,
"value": 3,
"vis": 8
},
"word_counts": {
"1": 2,
"2": 1,
"a": 1,
"ai_models": 1,
"all": 1,
"analyze": 1,
"and": 2,
"available": 2,
"bert": 3,
"bert_inference": 1,
"component": 4,
"components": 1,
"confidence": 1,
"content": 1,
"core": 5,
"demo": 1,
"development": 1,
"embedding": 2,
"embeddings": 1,
"error": 1,
"example": 1,
"executed": 4,
"experimental": 3,
"failed": 1,
"feature": 2,
"for": 2,
"generate": 1,
"generator": 1,
"get": 1,
"getting": 1,
"hello": 1,
"inference": 2,
"initialize": 1,
"initializing": 1,
"input": 2,
"invocation": 2,
"manual": 1,
"mcp": 3,
"menu": 1,
"model": 2,
"of": 1,
"on": 1,
"predictions": 2,
"process": 1,
"processor": 1,
"registered": 1,
"result": 1,
"run": 1,
"scores": 1,
"specific": 1,
"successfully": 4,
"system": 2,
"test": 4,
"text": 5,
"tool": 3,
"tools": 4,
"under": 1,
"world": 1
},
"word_emoji_counts": {
"1️⃣": 2,
"2️⃣": 1,
"📦": 1,
"🔬": 1
}
},
"timestamp": 1751588254
}