mcp-ollama-python 1.0.1__tar.gz → 1.0.2__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.
Files changed (23) hide show
  1. {mcp_ollama_python-1.0.1 → mcp_ollama_python-1.0.2}/PKG-INFO +3 -3
  2. {mcp_ollama_python-1.0.1 → mcp_ollama_python-1.0.2}/README.md +1 -1
  3. {mcp_ollama_python-1.0.1 → mcp_ollama_python-1.0.2}/pyproject.toml +2 -2
  4. mcp_ollama_python-1.0.1/src/mcp_ollama_python/examples/get_spanish_poem.py +0 -59
  5. {mcp_ollama_python-1.0.1 → mcp_ollama_python-1.0.2}/LICENSE +0 -0
  6. {mcp_ollama_python-1.0.1 → mcp_ollama_python-1.0.2}/src/mcp_ollama_python/__init__.py +0 -0
  7. {mcp_ollama_python-1.0.1 → mcp_ollama_python-1.0.2}/src/mcp_ollama_python/__main__.py +0 -0
  8. {mcp_ollama_python-1.0.1 → mcp_ollama_python-1.0.2}/src/mcp_ollama_python/autoloader.py +0 -0
  9. {mcp_ollama_python-1.0.1 → mcp_ollama_python-1.0.2}/src/mcp_ollama_python/main.py +0 -0
  10. {mcp_ollama_python-1.0.1 → mcp_ollama_python-1.0.2}/src/mcp_ollama_python/models.py +0 -0
  11. {mcp_ollama_python-1.0.1 → mcp_ollama_python-1.0.2}/src/mcp_ollama_python/ollama_client.py +0 -0
  12. {mcp_ollama_python-1.0.1 → mcp_ollama_python-1.0.2}/src/mcp_ollama_python/response_formatter.py +0 -0
  13. {mcp_ollama_python-1.0.1 → mcp_ollama_python-1.0.2}/src/mcp_ollama_python/server.py +0 -0
  14. {mcp_ollama_python-1.0.1 → mcp_ollama_python-1.0.2}/src/mcp_ollama_python/tools/__init__.py +0 -0
  15. {mcp_ollama_python-1.0.1 → mcp_ollama_python-1.0.2}/src/mcp_ollama_python/tools/chat.py +0 -0
  16. {mcp_ollama_python-1.0.1 → mcp_ollama_python-1.0.2}/src/mcp_ollama_python/tools/delete.py +0 -0
  17. {mcp_ollama_python-1.0.1 → mcp_ollama_python-1.0.2}/src/mcp_ollama_python/tools/embed.py +0 -0
  18. {mcp_ollama_python-1.0.1 → mcp_ollama_python-1.0.2}/src/mcp_ollama_python/tools/execute.py +0 -0
  19. {mcp_ollama_python-1.0.1 → mcp_ollama_python-1.0.2}/src/mcp_ollama_python/tools/generate.py +0 -0
  20. {mcp_ollama_python-1.0.1 → mcp_ollama_python-1.0.2}/src/mcp_ollama_python/tools/list.py +0 -0
  21. {mcp_ollama_python-1.0.1 → mcp_ollama_python-1.0.2}/src/mcp_ollama_python/tools/ps.py +0 -0
  22. {mcp_ollama_python-1.0.1 → mcp_ollama_python-1.0.2}/src/mcp_ollama_python/tools/pull.py +0 -0
  23. {mcp_ollama_python-1.0.1 → mcp_ollama_python-1.0.2}/src/mcp_ollama_python/tools/show.py +0 -0
@@ -1,9 +1,9 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: mcp-ollama-python
3
- Version: 1.0.1
3
+ Version: 1.0.2
4
4
  Summary: Model Context Protocol server that proxies local Ollama to MCP clients like Windsurf and VS Code
5
5
  License-File: LICENSE
6
- Author: Your Name
6
+ Author: Pedja Blagojevic
7
7
  Author-email: pb@internetics.net
8
8
  Requires-Python: >=3.10,<3.15
9
9
  Classifier: Programming Language :: Python :: 3
@@ -508,7 +508,7 @@ Ask codeium to use local MCP Ollama with gpt-oss model for LLM tasks, it will cr
508
508
  Technical analysis
509
509
  Q&A about code or concepts
510
510
  Any other LLM-powered assistance
511
- Project context: mcp-ollama-python (d:\Pdj\gitHub\mcp-ollama-python)
511
+ Project context: mcp-ollama-python (C:\myCode\gitHub\mcp-ollama-python)
512
512
 
513
513
  ## 🤝 Contributing
514
514
 
@@ -486,7 +486,7 @@ Ask codeium to use local MCP Ollama with gpt-oss model for LLM tasks, it will cr
486
486
  Technical analysis
487
487
  Q&A about code or concepts
488
488
  Any other LLM-powered assistance
489
- Project context: mcp-ollama-python (d:\Pdj\gitHub\mcp-ollama-python)
489
+ Project context: mcp-ollama-python (C:\myCode\gitHub\mcp-ollama-python)
490
490
 
491
491
  ## 🤝 Contributing
492
492
 
@@ -1,8 +1,8 @@
1
1
  [tool.poetry]
2
2
  name = "mcp-ollama-python"
3
- version = "1.0.1"
3
+ version = "1.0.2"
4
4
  description = "Model Context Protocol server that proxies local Ollama to MCP clients like Windsurf and VS Code"
5
- authors = ["Your Name <pb@internetics.net>"]
5
+ authors = ["Pedja Blagojevic <pb@internetics.net>"]
6
6
  readme = "README.md"
7
7
  packages = [{include = "mcp_ollama_python", from = "src"}]
8
8
 
@@ -1,59 +0,0 @@
1
- """
2
- Get a Spanish poem using local MCP Ollama server with gpt-oss model
3
- """
4
-
5
- import asyncio
6
- import json
7
- from mcp_ollama_python.ollama_client import OllamaClient
8
- from mcp_ollama_python.models import ChatMessage
9
-
10
-
11
- async def get_spanish_poem():
12
- """Generate a Spanish poem using gpt-oss model"""
13
- print("Connecting to Ollama server...")
14
- client = OllamaClient()
15
-
16
- print("Requesting Spanish poem from gpt-oss model...")
17
-
18
- # Create chat message
19
- messages = [
20
- ChatMessage(
21
- role="user",
22
- content="Escribe un poema bonito en español sobre la vida, el amor y la esperanza. Hazlo corto pero emotivo.",
23
- )
24
- ]
25
-
26
- try:
27
- # Call Ollama chat API
28
- result = await client.chat(model="gpt-oss", messages=messages)
29
-
30
- # Extract the response
31
- if result and "message" in result:
32
- poem = result["message"].get("content", "")
33
- print("\n" + "=" * 60)
34
- print("POEMA EN ESPAÑOL (Spanish Poem)")
35
- print("=" * 60)
36
- print(poem)
37
- print("=" * 60)
38
- return poem
39
- else:
40
- print("Error: No response received")
41
- print(f"Result: {json.dumps(result, indent=2)}")
42
- return None
43
- except Exception as e:
44
- print(f"Error calling Ollama: {e}")
45
- return None
46
- finally:
47
- await client.client.aclose()
48
-
49
-
50
- if __name__ == "__main__":
51
- try:
52
- asyncio.run(get_spanish_poem())
53
- except KeyboardInterrupt:
54
- print("\n\nInterrupted by user")
55
- except Exception as e:
56
- print(f"\nError: {e}")
57
- import traceback
58
-
59
- traceback.print_exc()