mirror of
https://github.com/PrefectHQ/fastmcp.git
synced 2026-08-23 14:04:18 +02:00
Update environment note (#1075)
* Update environment note * Update memory.py
This commit is contained in:
parent
6c9263001b
commit
45c4ceb1bd
3 changed files with 8 additions and 8 deletions
|
|
@ -2,7 +2,7 @@ fail_fast: false
|
|||
|
||||
repos:
|
||||
- repo: https://github.com/abravalheri/validate-pyproject
|
||||
rev: v0.23
|
||||
rev: v0.24.1
|
||||
hooks:
|
||||
- id: validate-pyproject
|
||||
|
||||
|
|
@ -14,10 +14,10 @@ repos:
|
|||
|
||||
- repo: https://github.com/astral-sh/ruff-pre-commit
|
||||
# Ruff version.
|
||||
rev: v0.11.4
|
||||
rev: v0.12.1
|
||||
hooks:
|
||||
# Run the linter.
|
||||
- id: ruff
|
||||
- id: ruff-check
|
||||
args: [--fix, --exit-non-zero-on-fix]
|
||||
# Run the formatter.
|
||||
- id: ruff-format
|
||||
|
|
|
|||
|
|
@ -160,7 +160,7 @@ fastmcp install cursor server.py
|
|||
fastmcp install mcp-json server.py
|
||||
```
|
||||
|
||||
Note that for security reasons, MCP clients run every server in a completely isolated environment. Therefore, all dependencies must be explicitly specified using the `--with` and/or `--with-editable` options (following `uv` conventions) or by attaching them to your server in code via the `dependencies` parameter.
|
||||
Note that for security reasons, MCP clients usually run every server in a completely isolated environment. Therefore, all dependencies must be explicitly specified using the `--with` and/or `--with-editable` options (following `uv` conventions) or by attaching them to your server in code via the `dependencies` parameter. You should not assume that the MCP server will have access to your local environment.
|
||||
|
||||
<Warning>
|
||||
**`uv` must be installed and available in your system PATH**. Both Claude Desktop and Cursor run in isolated environments and need `uv` to manage dependencies. On macOS, install `uv` globally with Homebrew for Claude Desktop compatibility: `brew install uv`.
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@ import os
|
|||
from dataclasses import dataclass
|
||||
from datetime import datetime, timezone
|
||||
from pathlib import Path
|
||||
from typing import Annotated, Self
|
||||
from typing import Annotated, Any, Self
|
||||
|
||||
import asyncpg
|
||||
import numpy as np
|
||||
|
|
@ -60,12 +60,12 @@ def cosine_similarity(a: list[float], b: list[float]) -> float:
|
|||
)
|
||||
|
||||
|
||||
async def do_ai[T](
|
||||
async def do_ai(
|
||||
user_prompt: str,
|
||||
system_prompt: str,
|
||||
result_type: type[T] | Annotated,
|
||||
result_type: type | Annotated,
|
||||
deps=None,
|
||||
) -> T:
|
||||
) -> Any:
|
||||
agent = Agent(
|
||||
DEFAULT_LLM_MODEL,
|
||||
system_prompt=system_prompt,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue