text_alalyzer
服务介绍
Text Analyzer MCP Server
AI FastMCP .
(Tools)
-
count_characters(text, include_spaces) -
-
count_words(text) -
-
analyze_character_types(text) -
- , , ,
- , ,
-
get_text_statistics(text) -
- , , ,
-
check_text_length_limit(text, max_length) -
- /
- text_analyzer://help -
1.
#
python -m venv venv
#
# Windows:
venv\Scripts\activate
# macOS/Linux:
source venv/bin/activate
#
pip install -r requirements.txt
2.
()
# MCP Inspector ( )
fastmcp dev text_analyzer_server.py
# Python
python text_analyzer_server.py
# FastMCP CLI
fastmcp run text_analyzer_server.py
3. AI
Claude Desktop
claude_desktop_config.json :
{
"mcpServers": {
"text_analyzer": {
"command": "python",
"args": ["/path/to/text_analyzer_server.py"]
}
}
}
VS Code/Cursor
.vscode/mcp.json .cursor/mcp.json :
{
"servers": {
"text_analyzer": {
"type": "stdio",
"command": "python",
"args": ["/path/to/text_analyzer_server.py"]
}
}
}
# AI
# " Hello World!" .
count_characters(" Hello World!", True)
# :
# {
# "total_characters": 18,
# "characters_without_spaces": 16,
# "spaces_count": 2,
# "final_count": 18
# }
get_text_statistics("! .")
# , ,
check_text_length_limit(" ", 100)
# 100
MCP FastMCP .
- ** **:
- ** **: MCP
- ** **: Python
#
fastmcp dev text_analyzer_server.py --verbose
MIT License
GitHub Issues .