Files

32 lines
941 B
Python
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
"""
registry/service.py – Model registry service (Phase 1 stub).
Responsibilities (to be completed in Phase 11):
- Search Hugging Face Hub for GGUF models
- Download models with resume support + checksum validation
- Maintain a local index of available models
- Expose a simple JSON IPC socket for the Rust server
This file intentionally minimal in Phase 1. The structure is here so the
Rust server can already reference the IPC path in its config.
"""
import json
import os
import socket
import sys
from pathlib import Path
MODELS_DIR = Path(os.environ.get("LOCALLLM_MODELS_DIR", "../models"))
IPC_SOCKET = os.environ.get("LOCALLLM_REGISTRY_SOCK", "/tmp/localllm-registry.sock")
def main():
print(f"[registry] models dir : {MODELS_DIR.resolve()}")
print(f"[registry] IPC socket : {IPC_SOCKET}")
print("[registry] Phase 1 stub – no-op. Full implementation in Phase 11.")
if __name__ == "__main__":
main()