macro_rules! ai_instructions {
($service:expr $(, $part:expr)+ $(,)?) => { ... };
($service:expr $(,)?) => { ... };
}Expand description
构造一段编译期 _ai_instructions 文本。
用法:
ⓘ
// 在使用方 crate(例如 sts-x)里:
const HINT: &str = core_lib::ai_instructions!(
"STS-X",
"unified code+file search. CLI: sts-x search \"q\". MCP: POST /search."
);
// 展开 ≈ "I am STS-X 3.1.2. unified code+file search. ..."第一个参数是服务名,其余参数按 concat! 依次拼接。版本号取自调用方 crate 的
CARGO_PKG_VERSION,因此各 app 无需手写版本。