neuralnode 2.1.11__tar.gz → 2.1.12__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.
- {neuralnode-2.1.11 → neuralnode-2.1.12}/PKG-INFO +1 -1
- {neuralnode-2.1.11 → neuralnode-2.1.12}/pyproject.toml +1 -1
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/__init__.py +1 -1
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/providers/horus.py +89 -33
- neuralnode-2.1.12/temp_header.gguf +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/.env.example +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/.github/workflows/tests.yml +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/Dockerfile +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/LICENSE +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/README.md +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/docker-compose.yml +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/docs/documentation.md +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/docs/ecosystem_plan.md +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/docs/replica_voice_ids.csv +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/docs/replica_voice_ids.md +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/docs/telegram_guide.md +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/agent_with_tools.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/basic_chat.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/01_basic_usage.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/02_horus_lens.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/03_one_liner.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/04_custom_cache.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/05_4bit_quantization.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/06_8bit_quantization.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/07_multi_gpu.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/08_flash_attention.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/09_data_types.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/10_generation_params.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/11_streaming.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/12_chat_templates.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/13_offline_mode.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/14_force_download.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/15_model_info.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/16_cpu_offloading.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/17_cpu_only.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/18_production_setup.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/19_gguf_4bit.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/20_gguf_5bit.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/21_gguf_6bit.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/22_gguf_8bit.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/23_gguf_16bit.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/24_list_models.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/25_interactive_chat.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/README.md +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_download_guide.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_examples.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_tq_ready_gguf.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_transformers_features.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/local_models.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/neuralnode_v21_complete_demo.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/shade_model_with_tools.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/telegram_bot_demo.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/thinking_mode_example.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/tts_demo.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/turboquant_example.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/examples/v3_features.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/horus_chat_voice.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/neuralnode_horus_replica_telegram.ipynb +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/publish.bat +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/publish.sh +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/requirements_shade.txt +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/scripts/setup.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/debug_import.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/agents/__init__.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/chains/__init__.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/config/__init__.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/core/__init__.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/core/openai_blocker.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/diagnostics/__init__.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/integrations/discord.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/integrations/slack.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/integrations/telegram.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/integrations/whatsapp.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/memory/__init__.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/memory/advanced.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/prompts/__init__.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/providers/__init__.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/providers/base.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/providers/chat/__init__.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/providers/chat/ai21.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/providers/chat/anthropic.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/providers/chat/cohere.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/providers/chat/deepseek.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/providers/chat/fireworks.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/providers/chat/google.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/providers/chat/groq.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/providers/chat/mistral.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/providers/chat/perplexity.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/providers/chat/together.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/providers/chat_models.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/providers/embeddings.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/providers/local/__init__.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/providers/local_providers.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/providers/text_generation.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/providers/universal_local.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/rag/__init__.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/rag/loaders.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/reasoning/__init__.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/replica.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/speech/__init__.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/thinking.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/tools/__init__.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/tools/advanced.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/tools/multisearch.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/tools/system/__init__.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/tools/system/operations.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/tools/web/__init__.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/tts/__init__.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/turboquant.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/utils/__init__.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/utils/dependencies.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/utils/logger.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/utils/metrics.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/vectorstores/__init__.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/neuralnode/vision/__init__.py +0 -0
- {neuralnode-2.1.11 → neuralnode-2.1.12}/src/nn/__init__.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: neuralnode
|
|
3
|
-
Version: 2.1.
|
|
3
|
+
Version: 2.1.12
|
|
4
4
|
Summary: Comprehensive AI Framework with 50+ LLM Providers, Advanced Agents, Chains, Memory, RAG, and 100+ Tools
|
|
5
5
|
Project-URL: Homepage, https://assem.cloud/
|
|
6
6
|
Project-URL: Documentation, https://neuralnode.readthedocs.io
|
|
@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "neuralnode"
|
|
7
|
-
version = "2.1.
|
|
7
|
+
version = "2.1.12"
|
|
8
8
|
description = "Comprehensive AI Framework with 50+ LLM Providers, Advanced Agents, Chains, Memory, RAG, and 100+ Tools"
|
|
9
9
|
readme = "README.md"
|
|
10
10
|
requires-python = ">=3.9"
|
|
@@ -477,13 +477,23 @@ class HorusProvider(BaseLLMProvider):
|
|
|
477
477
|
with redirect_stdout(devnull), redirect_stderr(devnull):
|
|
478
478
|
yield
|
|
479
479
|
finally:
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
480
|
+
# Always restore fds and close devnull, even if yield raised.
|
|
481
|
+
try:
|
|
482
|
+
if old_stdout_fd is not None:
|
|
483
|
+
os.dup2(old_stdout_fd, 1)
|
|
484
|
+
os.close(old_stdout_fd)
|
|
485
|
+
except OSError:
|
|
486
|
+
pass
|
|
487
|
+
try:
|
|
488
|
+
if old_stderr_fd is not None:
|
|
489
|
+
os.dup2(old_stderr_fd, 2)
|
|
490
|
+
os.close(old_stderr_fd)
|
|
491
|
+
except OSError:
|
|
492
|
+
pass
|
|
493
|
+
try:
|
|
494
|
+
devnull.close()
|
|
495
|
+
except OSError:
|
|
496
|
+
pass
|
|
487
497
|
|
|
488
498
|
def _resolve_device(self) -> str:
|
|
489
499
|
if torch is not None and torch.cuda.is_available():
|
|
@@ -532,10 +542,12 @@ class HorusProvider(BaseLLMProvider):
|
|
|
532
542
|
return False
|
|
533
543
|
if not cls._is_gguf_model_id(model_id):
|
|
534
544
|
return False
|
|
535
|
-
# Check the registry first
|
|
545
|
+
# Check the registry first (both 'task' and 'type' fields)
|
|
536
546
|
info = cls.HORUS_MODELS.get(model_id, {})
|
|
537
547
|
if str(info.get("task", "")).lower() == "text-to-image":
|
|
538
548
|
return True
|
|
549
|
+
if str(info.get("type", "")).lower() == "gguf" and "lens" in model_id.lower():
|
|
550
|
+
return True
|
|
539
551
|
# Heuristic: "lens" in the model path means text-to-image
|
|
540
552
|
return "lens" in model_id.lower()
|
|
541
553
|
|
|
@@ -731,13 +743,28 @@ class HorusProvider(BaseLLMProvider):
|
|
|
731
743
|
"Install with: pip install gguf"
|
|
732
744
|
)
|
|
733
745
|
|
|
734
|
-
# Force diffusers to recognize the newly installed gguf package
|
|
746
|
+
# Force diffusers to recognize the newly installed gguf package.
|
|
747
|
+
# Guard against versions like 'N/A' (local/editable builds) that break
|
|
748
|
+
# packaging.version.parse and cause an InvalidVersion crash inside
|
|
749
|
+
# diffusers.quantizers.gguf.gguf_quantizer.validate_environment().
|
|
735
750
|
try:
|
|
736
751
|
import sys
|
|
752
|
+
import importlib.metadata
|
|
753
|
+
from packaging.version import Version
|
|
754
|
+
try:
|
|
755
|
+
raw_version = importlib.metadata.version("gguf")
|
|
756
|
+
# Validate the version string before injecting it.
|
|
757
|
+
Version(raw_version)
|
|
758
|
+
version = raw_version
|
|
759
|
+
except Exception:
|
|
760
|
+
# Fall back to a known-good sentinel that satisfies diffusers >= 0.10.0 check
|
|
761
|
+
version = "0.19.0"
|
|
737
762
|
if "diffusers.utils.import_utils" in sys.modules:
|
|
738
763
|
sys.modules["diffusers.utils.import_utils"]._gguf_available = True
|
|
764
|
+
sys.modules["diffusers.utils.import_utils"]._gguf_version = version
|
|
739
765
|
import diffusers.utils.import_utils as diffusers_import_utils
|
|
740
766
|
diffusers_import_utils._gguf_available = True
|
|
767
|
+
diffusers_import_utils._gguf_version = version
|
|
741
768
|
except Exception:
|
|
742
769
|
pass
|
|
743
770
|
|
|
@@ -801,13 +828,35 @@ class HorusProvider(BaseLLMProvider):
|
|
|
801
828
|
**transformer_kwargs
|
|
802
829
|
)
|
|
803
830
|
except Exception as exc:
|
|
831
|
+
# Try without quantization_config first (handles shape mismatch
|
|
832
|
+
# caused by mismatched ZImageTransformer2DModel config when
|
|
833
|
+
# the GGUF was built with a different architecture variant).
|
|
834
|
+
plain_kwargs = {"torch_dtype": compute_dtype}
|
|
804
835
|
try:
|
|
805
836
|
transformer = ZImageTransformer2DModel.from_single_file(
|
|
806
837
|
model_path,
|
|
807
|
-
|
|
838
|
+
**plain_kwargs
|
|
808
839
|
)
|
|
809
840
|
except Exception:
|
|
810
|
-
|
|
841
|
+
# Last resort: allow size mismatch so at least something loads
|
|
842
|
+
try:
|
|
843
|
+
transformer = ZImageTransformer2DModel.from_single_file(
|
|
844
|
+
model_path,
|
|
845
|
+
ignore_mismatched_sizes=True,
|
|
846
|
+
low_cpu_mem_usage=False,
|
|
847
|
+
**plain_kwargs
|
|
848
|
+
)
|
|
849
|
+
logger.warning(
|
|
850
|
+
"Loaded GGUF transformer with ignored size mismatches. "
|
|
851
|
+
"Image quality may be degraded. Consider using the full (non-GGUF) "
|
|
852
|
+
"Horus-Lens-1.0 model for best results."
|
|
853
|
+
)
|
|
854
|
+
except Exception:
|
|
855
|
+
raise RuntimeError(
|
|
856
|
+
f"Failed to load GGUF transformer from '{model_path}': {exc}\n"
|
|
857
|
+
"Hint: The GGUF file may be incompatible with the installed diffusers "
|
|
858
|
+
"version. Try: pip install --upgrade diffusers"
|
|
859
|
+
)
|
|
811
860
|
|
|
812
861
|
base_repo_id = "tokenaii/Horus-Lens-1.0"
|
|
813
862
|
pipeline_kwargs: Dict[str, Any] = {
|
|
@@ -911,23 +960,25 @@ class HorusProvider(BaseLLMProvider):
|
|
|
911
960
|
prev_disable_progress = os.environ.get("HF_HUB_DISABLE_PROGRESS_BARS")
|
|
912
961
|
if self.suppress_native_output:
|
|
913
962
|
os.environ["HF_HUB_DISABLE_PROGRESS_BARS"] = "1"
|
|
914
|
-
|
|
915
|
-
warnings.
|
|
916
|
-
|
|
917
|
-
|
|
918
|
-
|
|
919
|
-
|
|
920
|
-
|
|
921
|
-
|
|
922
|
-
|
|
923
|
-
|
|
924
|
-
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
963
|
+
try:
|
|
964
|
+
with warnings.catch_warnings():
|
|
965
|
+
warnings.filterwarnings(
|
|
966
|
+
"ignore",
|
|
967
|
+
message=r".*You are sending unauthenticated requests to the HF Hub.*",
|
|
968
|
+
)
|
|
969
|
+
model_path = hf_hub_download(
|
|
970
|
+
repo_id=repo_id,
|
|
971
|
+
filename=filename,
|
|
972
|
+
cache_dir=self.cache_dir,
|
|
973
|
+
local_files_only=self.local_files_only,
|
|
974
|
+
token=self.token,
|
|
975
|
+
)
|
|
976
|
+
finally:
|
|
977
|
+
if self.suppress_native_output:
|
|
978
|
+
if prev_disable_progress is None:
|
|
979
|
+
os.environ.pop("HF_HUB_DISABLE_PROGRESS_BARS", None)
|
|
980
|
+
else:
|
|
981
|
+
os.environ["HF_HUB_DISABLE_PROGRESS_BARS"] = prev_disable_progress
|
|
931
982
|
|
|
932
983
|
llama_kwargs: Dict[str, Any] = {
|
|
933
984
|
"model_path": model_path,
|
|
@@ -1538,17 +1589,23 @@ class HorusProvider(BaseLLMProvider):
|
|
|
1538
1589
|
# Add tool descriptions to system prompt if tools are provided
|
|
1539
1590
|
if tools:
|
|
1540
1591
|
tool_desc = self._format_tool_descriptions(tools)
|
|
1592
|
+
tool_section = (
|
|
1593
|
+
"\n\nAvailable tools:\n"
|
|
1594
|
+
+ tool_desc
|
|
1595
|
+
+ "\n\nTo call a tool, respond with valid JSON: "
|
|
1596
|
+
'{"tool": "<name>", "arguments": {"<param>": "<value>"}}'
|
|
1597
|
+
)
|
|
1541
1598
|
# Find system message or add one
|
|
1542
1599
|
has_system = False
|
|
1543
1600
|
for m in normalized:
|
|
1544
1601
|
if m["role"] == "system":
|
|
1545
|
-
m["content"] = m["content"] +
|
|
1602
|
+
m["content"] = m["content"] + tool_section
|
|
1546
1603
|
has_system = True
|
|
1547
1604
|
break
|
|
1548
1605
|
if not has_system:
|
|
1549
1606
|
normalized.insert(0, {
|
|
1550
1607
|
"role": "system",
|
|
1551
|
-
"content": UNIFIED_SYSTEM_PROMPT +
|
|
1608
|
+
"content": UNIFIED_SYSTEM_PROMPT + tool_section
|
|
1552
1609
|
})
|
|
1553
1610
|
|
|
1554
1611
|
prompt = self._render_prompt(normalized)
|
|
@@ -1591,7 +1648,7 @@ class HorusProvider(BaseLLMProvider):
|
|
|
1591
1648
|
)
|
|
1592
1649
|
|
|
1593
1650
|
async def achat(self, messages: List[Dict[str, Any]], **kwargs) -> Union[LLMResponse, Iterator[StreamingChunk]]:
|
|
1594
|
-
loop = asyncio.
|
|
1651
|
+
loop = asyncio.get_running_loop()
|
|
1595
1652
|
return await loop.run_in_executor(None, lambda: self.chat(messages, **kwargs))
|
|
1596
1653
|
|
|
1597
1654
|
def complete(self, prompt: str, model: Optional[str] = None, **kwargs) -> LLMResponse:
|
|
@@ -1719,8 +1776,7 @@ class HorusProvider(BaseLLMProvider):
|
|
|
1719
1776
|
|
|
1720
1777
|
async def aembed(self, texts: Union[str, List[str]], model: Optional[str] = None, **kwargs) -> Union[List[float], List[List[float]]]:
|
|
1721
1778
|
"""Async version of embed - runs in executor."""
|
|
1722
|
-
|
|
1723
|
-
loop = asyncio.get_event_loop()
|
|
1779
|
+
loop = asyncio.get_running_loop()
|
|
1724
1780
|
return await loop.run_in_executor(None, lambda: self.embed(texts, model=model, **kwargs))
|
|
1725
1781
|
|
|
1726
1782
|
def get_model_info(self) -> Dict[str, Any]:
|
|
Binary file
|
|
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
|
{neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/05_4bit_quantization.py
RENAMED
|
File without changes
|
{neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/06_8bit_quantization.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{neuralnode-2.1.11 → neuralnode-2.1.12}/examples/horus_codes_camples/10_generation_params.py
RENAMED
|
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
|
|
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
|
|
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
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|