MCPcopy Create free account
hub / github.com/Louisym/MiniCC / truncate_summary

Function truncate_summary

mini_claude_code/compact.py:98–102  ·  view source on GitHub ↗

源码: compact.rs:317-324

(text: str, max_chars: int = 160)

Source from the content-addressed store, hash-verified

96# ============================================================
97
98def truncate_summary(text: str, max_chars: int = 160) -> str:
99 """源码: compact.rs:317-324"""
100 if len(text) <= max_chars:
101 return text
102 return text[:max_chars] + "…"
103
104
105_INTERESTING_EXTENSIONS = {"py", "rs", "ts", "tsx", "js", "json", "md", "toml", "yaml", "yml"}

Callers 4

summarize_messagesFunction · 0.70
_infer_pending_workFunction · 0.70
_infer_current_workFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected