fenix-mcp 0.2.2__tar.gz → 0.4.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/PKG-INFO +1 -1
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp/__init__.py +1 -1
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp/application/tools/intelligence.py +15 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp/domain/intelligence.py +36 -3
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp/infrastructure/fenix_api/client.py +2 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp.egg-info/PKG-INFO +1 -1
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/README.md +0 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp/application/presenters.py +0 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp/application/tool_base.py +0 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp/application/tool_registry.py +0 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp/application/tools/__init__.py +0 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp/application/tools/health.py +0 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp/application/tools/initialize.py +0 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp/application/tools/knowledge.py +0 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp/application/tools/productivity.py +0 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp/application/tools/user_config.py +0 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp/domain/initialization.py +0 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp/domain/knowledge.py +0 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp/domain/productivity.py +0 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp/domain/user_config.py +0 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp/infrastructure/config.py +0 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp/infrastructure/context.py +0 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp/infrastructure/http_client.py +0 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp/infrastructure/logging.py +0 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp/interface/mcp_server.py +0 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp/interface/transports.py +0 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp/main.py +0 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp.egg-info/SOURCES.txt +0 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp.egg-info/dependency_links.txt +0 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp.egg-info/entry_points.txt +0 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp.egg-info/requires.txt +0 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/fenix_mcp.egg-info/top_level.txt +0 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/pyproject.toml +0 -0
- {fenix_mcp-0.2.2 → fenix_mcp-0.4.0}/setup.cfg +0 -0
|
@@ -71,6 +71,14 @@ class IntelligenceRequest(ToolRequest):
|
|
|
71
71
|
importance: str = Field(
|
|
72
72
|
default="medium", description="Nível de importância da memória."
|
|
73
73
|
)
|
|
74
|
+
include_content: bool = Field(
|
|
75
|
+
default=False,
|
|
76
|
+
description="Retornar conteúdo completo das memórias? Defina true para incluir o texto integral.",
|
|
77
|
+
)
|
|
78
|
+
include_metadata: bool = Field(
|
|
79
|
+
default=False,
|
|
80
|
+
description="Retornar metadata completa das memórias? Defina true para incluir o campo bruto.",
|
|
81
|
+
)
|
|
74
82
|
tags: Optional[List[str]] = Field(default=None, description="Tags da memória.")
|
|
75
83
|
limit: int = Field(default=20, ge=1, le=100, description="Limite de resultados.")
|
|
76
84
|
offset: int = Field(default=0, ge=0, description="Offset para paginação.")
|
|
@@ -167,6 +175,13 @@ class IntelligenceTool(Tool):
|
|
|
167
175
|
offset=payload.offset,
|
|
168
176
|
query=payload.query,
|
|
169
177
|
tags=payload.tags,
|
|
178
|
+
include_content=payload.include_content,
|
|
179
|
+
include_metadata=payload.include_metadata,
|
|
180
|
+
modeId=payload.mode_id,
|
|
181
|
+
ruleId=payload.rule_id,
|
|
182
|
+
workItemId=payload.work_item_id,
|
|
183
|
+
sprintId=payload.sprint_id,
|
|
184
|
+
documentationItemId=payload.documentation_item_id,
|
|
170
185
|
category=payload.category,
|
|
171
186
|
dateFrom=payload.date_from,
|
|
172
187
|
dateTo=payload.date_to,
|
|
@@ -42,14 +42,31 @@ class IntelligenceService:
|
|
|
42
42
|
|
|
43
43
|
async def query_memories(self, **filters: Any) -> List[Dict[str, Any]]:
|
|
44
44
|
params = _strip_none(filters)
|
|
45
|
-
include_content =
|
|
46
|
-
|
|
45
|
+
include_content = _coerce_bool(
|
|
46
|
+
params.pop("include_content", params.pop("content", None))
|
|
47
|
+
)
|
|
48
|
+
include_metadata = _coerce_bool(
|
|
49
|
+
params.pop("include_metadata", params.pop("metadata", None))
|
|
50
|
+
)
|
|
51
|
+
allowed_keys = {
|
|
52
|
+
"limit",
|
|
53
|
+
"offset",
|
|
54
|
+
"query",
|
|
55
|
+
"tags",
|
|
56
|
+
"modeId",
|
|
57
|
+
"ruleId",
|
|
58
|
+
"workItemId",
|
|
59
|
+
"sprintId",
|
|
60
|
+
"documentationItemId",
|
|
61
|
+
"importance",
|
|
62
|
+
}
|
|
63
|
+
cleaned_params = {key: params[key] for key in allowed_keys if key in params}
|
|
47
64
|
return (
|
|
48
65
|
await self._call(
|
|
49
66
|
self.api.list_memories,
|
|
50
67
|
include_content=include_content,
|
|
51
68
|
include_metadata=include_metadata,
|
|
52
|
-
**
|
|
69
|
+
**cleaned_params,
|
|
53
70
|
)
|
|
54
71
|
or []
|
|
55
72
|
)
|
|
@@ -141,5 +158,21 @@ def _importance_to_priority(importance: Optional[str]) -> float:
|
|
|
141
158
|
return mapping.get(importance.lower(), 0.5)
|
|
142
159
|
|
|
143
160
|
|
|
161
|
+
def _coerce_bool(value: Any, default: bool = False) -> bool:
|
|
162
|
+
if value is None or value == "":
|
|
163
|
+
return default
|
|
164
|
+
if isinstance(value, bool):
|
|
165
|
+
return value
|
|
166
|
+
if isinstance(value, (int, float)):
|
|
167
|
+
return bool(value)
|
|
168
|
+
if isinstance(value, str):
|
|
169
|
+
normalized = value.strip().lower()
|
|
170
|
+
if normalized in {"true", "1", "yes", "y"}:
|
|
171
|
+
return True
|
|
172
|
+
if normalized in {"false", "0", "no", "n"}:
|
|
173
|
+
return False
|
|
174
|
+
return bool(value)
|
|
175
|
+
|
|
176
|
+
|
|
144
177
|
def _strip_none(data: Dict[str, Any]) -> Dict[str, Any]:
|
|
145
178
|
return {key: value for key, value in data.items() if value not in (None, "")}
|
|
@@ -16,6 +16,8 @@ class FenixApiError(RuntimeError):
|
|
|
16
16
|
def _to_query_value(value: Any) -> Any:
|
|
17
17
|
if isinstance(value, bool):
|
|
18
18
|
return "true" if value else "false"
|
|
19
|
+
if isinstance(value, (list, tuple, set)):
|
|
20
|
+
return ",".join(str(item) for item in value)
|
|
19
21
|
return value
|
|
20
22
|
|
|
21
23
|
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|