You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: crates/mcp-apollo-server/src/operations.rs
+20-1
Original file line number
Diff line number
Diff line change
@@ -187,8 +187,22 @@ impl Operation {
187
187
));
188
188
};
189
189
190
+
let tool:Tool = Tool::new(operation_name.clone(), description, schema);
191
+
let character_count = tool_character_length(&tool);
192
+
match character_count {
193
+
Ok(length) => tracing::info!(
194
+
"Tool {} loaded with a character count of {}. Estimated tokens: {}",
195
+
operation_name,
196
+
length,
197
+
length / 4// We don't know the tokenization algorithm, so we just use 4 characters per token as a rough estimate. https://docs.anthropic.com/en/docs/resources/glossary#tokens
0 commit comments