-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathconstants.py
More file actions
40 lines (32 loc) · 982 Bytes
/
constants.py
File metadata and controls
40 lines (32 loc) · 982 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
# Copyright (c) 2024 Travis Frisinger
#
# This source code is licensed under the MIT license found in the
# LICENSE file in the root directory of this source tree.
"""Constants for WebCat application."""
import os
# Application version
VERSION = "2.5.1"
# Service information
SERVICE_NAME = "WebCat MCP Server"
SERVICE_DESCRIPTION = "Web search and content extraction with MCP protocol support"
# Server capabilities
CAPABILITIES = [
"Web search with Serper API",
"DuckDuckGo fallback search",
"Content extraction and scraping",
"Markdown conversion",
"FastMCP protocol support",
]
# Content limits
try:
MAX_CONTENT_LENGTH = int(os.environ.get("MAX_CONTENT_LENGTH", "1000000"))
except ValueError:
MAX_CONTENT_LENGTH = 1000000
DEFAULT_SEARCH_RESULTS = 5
# Timeout settings
REQUEST_TIMEOUT_SECONDS = 5
HEARTBEAT_INTERVAL_SECONDS = 30
# Logging
DEFAULT_LOG_FILE = "webcat.log"
LOG_FILE_MAX_BYTES = 10 * 1024 * 1024 # 10MB
LOG_FILE_BACKUP_COUNT = 5