text
stringlengths
3
1.68M
id
stringlengths
13
169
metadata
dict
__index_level_0__
int64
0
2.21k
package writebuffer import ( "math" "github.com/cockroachdb/errors" "go.uber.org/zap" "github.com/milvus-io/milvus-proto/go-api/v2/msgpb" "github.com/milvus-io/milvus-proto/go-api/v2/schemapb" "github.com/milvus-io/milvus/internal/storage" "github.com/milvus-io/milvus/pkg/log" "github.com/milvus-io/milvus/pk...
milvus/internal/datanode/writebuffer/insert_buffer.go/0
{ "file_path": "milvus/internal/datanode/writebuffer/insert_buffer.go", "repo_id": "milvus", "token_count": 1351 }
1,928
# coding=utf-8 # Copyright 2021 The HuggingFace Inc. team # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable ...
transformers/src/transformers/generation/flax_logits_process.py/0
{ "file_path": "transformers/src/transformers/generation/flax_logits_process.py", "repo_id": "transformers", "token_count": 8086 }
561
python_tests()
llama_index/llama-index-integrations/tools/llama-index-tools-slack/tests/BUILD/0
{ "file_path": "llama_index/llama-index-integrations/tools/llama-index-tools-slack/tests/BUILD", "repo_id": "llama_index", "token_count": 5 }
1,438
# Copyright 2022 The HuggingFace Team. All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicabl...
transformers/tests/pipelines/test_pipelines_visual_question_answering.py/0
{ "file_path": "transformers/tests/pipelines/test_pipelines_visual_question_answering.py", "repo_id": "transformers", "token_count": 2897 }
762
<jupyter_start><jupyter_text>Query Pipeline with RoutingHere we showcase our query pipeline with routing.Routing lets us dynamically choose underlying query pipelines to use given the query and a set of choices.We offer this as an out-of-the-box abstraction in our [Router Query Engine](https://docs.llamaindex.ai/en/sta...
llama_index/docs/examples/pipeline/query_pipeline_routing.ipynb/0
{ "file_path": "llama_index/docs/examples/pipeline/query_pipeline_routing.ipynb", "repo_id": "llama_index", "token_count": 1531 }
1,079
python_tests( interpreter_constraints=["==3.9.*", "==3.10.*"], )
llama_index/llama-index-packs/llama-index-packs-vanna/tests/BUILD/0
{ "file_path": "llama_index/llama-index-packs/llama-index-packs-vanna/tests/BUILD", "repo_id": "llama_index", "token_count": 29 }
1,704
# coding=utf-8 # Copyright 2024 HuggingFace Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or ag...
diffusers/tests/pipelines/kandinsky/test_kandinsky_img2img.py/0
{ "file_path": "diffusers/tests/pipelines/kandinsky/test_kandinsky_img2img.py", "repo_id": "diffusers", "token_count": 6297 }
279
# Agents An "agent" is an automated reasoning and decision engine. It takes in a user input/query and can make internal decisions for executing that query in order to return the correct result. The key agent components can include, but are not limited to: - Breaking down a complex question into smaller ones - Choosin...
llama_index/docs/use_cases/agents.md/0
{ "file_path": "llama_index/docs/use_cases/agents.md", "repo_id": "llama_index", "token_count": 590 }
1,154
from typing import List import pytest as pytest from langchain_core.documents import Document from langchain.retrievers.multi_query import _unique_documents @pytest.mark.parametrize( "documents,expected", [ ([], []), ([Document(page_content="foo")], [Document(page_content="foo")]), (...
langchain/libs/langchain/tests/unit_tests/retrievers/test_multi_query.py/0
{ "file_path": "langchain/libs/langchain/tests/unit_tests/retrievers/test_multi_query.py", "repo_id": "langchain", "token_count": 656 }
638
python_sources()
llama_index/llama-index-integrations/vector_stores/llama-index-vector-stores-neo4jvector/llama_index/vector_stores/neo4jvector/BUILD/0
{ "file_path": "llama_index/llama-index-integrations/vector_stores/llama-index-vector-stores-neo4jvector/llama_index/vector_stores/neo4jvector/BUILD", "repo_id": "llama_index", "token_count": 6 }
1,470
--- hide_table_of_contents: true --- import CodeBlock from "@theme/CodeBlock"; import PairwiseEmbeddingDistance from "@examples/guides/evaluation/comparision_evaluator/pairwise_embedding_distance.ts"; # Pairwise Embedding Distance One way to measure the similarity (or dissimilarity) between two predictions on a shar...
langchainjs/docs/core_docs/docs/guides/evaluation/comparison/pairwise_embedding_distance.mdx/0
{ "file_path": "langchainjs/docs/core_docs/docs/guides/evaluation/comparison/pairwise_embedding_distance.mdx", "repo_id": "langchainjs", "token_count": 258 }
696
# Copyright 2022 The HuggingFace Team. All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicabl...
transformers/tests/models/clipseg/test_processor_clipseg.py/0
{ "file_path": "transformers/tests/models/clipseg/test_processor_clipseg.py", "repo_id": "transformers", "token_count": 3413 }
713
# coding=utf-8 # Copyright 2023 The HuggingFace Inc. team. All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless r...
transformers/tests/models/autoformer/test_modeling_autoformer.py/0
{ "file_path": "transformers/tests/models/autoformer/test_modeling_autoformer.py", "repo_id": "transformers", "token_count": 8817 }
705
import * as uuid from "uuid"; import { MultiVectorRetriever } from "langchain/retrievers/multi_vector"; import { FaissStore } from "@langchain/community/vectorstores/faiss"; import { OpenAIEmbeddings } from "@langchain/openai"; import { RecursiveCharacterTextSplitter } from "langchain/text_splitter"; import { InMemory...
langchainjs/examples/src/retrievers/multi_vector_small_chunks.ts/0
{ "file_path": "langchainjs/examples/src/retrievers/multi_vector_small_chunks.ts", "repo_id": "langchainjs", "token_count": 826 }
816
# Patentsview Loader This loader loads patent abstract from `a list of patent numbers` with API provided by [Patentsview](https://patentsview.org/). ## Usage Here'a an example usage of PatentsviewReader. ```python from llama_index import download_loader PatentsviewReader = download_loader("PatentsviewReader") load...
llama_index/llama-index-integrations/readers/llama-index-readers-patentsview/README.md/0
{ "file_path": "llama_index/llama-index-integrations/readers/llama-index-readers-patentsview/README.md", "repo_id": "llama_index", "token_count": 170 }
1,425
import os import tempfile from abc import ABC from typing import List from urllib.parse import urlparse import requests from langchain_community.docstore.document import Document from langchain_community.document_loaders.base import BaseLoader from langchain_community.document_loaders.blob_loaders import Blob from la...
langchain/libs/community/langchain_community/document_loaders/vsdx.py/0
{ "file_path": "langchain/libs/community/langchain_community/document_loaders/vsdx.py", "repo_id": "langchain", "token_count": 795 }
252
use super::utils::{ get_scale_min_k4, group_for_dequantization, group_for_quantization, make_q3_quants, make_qkx1_quants, make_qx_quants, nearest_int, }; use super::GgmlDType; use crate::Result; use byteorder::{ByteOrder, LittleEndian}; use half::f16; use rayon::prelude::*; // Default to QK_K 256 rather than 6...
candle/candle-core/src/quantized/k_quants.rs/0
{ "file_path": "candle/candle-core/src/quantized/k_quants.rs", "repo_id": "candle", "token_count": 42652 }
35
/* eslint-disable no-instanceof/no-instanceof */ import { ICacheClient, CacheGet, CacheSet, InvalidArgumentError, } from "@gomomento/sdk-core"; import { BaseCache, deserializeStoredGeneration, getCacheKey, serializeGeneration, } from "@langchain/core/caches"; import { Generation } from "@langchain/core...
langchainjs/libs/langchain-community/src/caches/momento.ts/0
{ "file_path": "langchainjs/libs/langchain-community/src/caches/momento.ts", "repo_id": "langchainjs", "token_count": 1811 }
1,048
<jupyter_start><jupyter_text>Self-querying:::infoHead to [Integrations](/docs/integrations/retrievers/self_query) for documentation on vector stores with built-in support for self-querying.:::A self-querying retriever is one that, as the name suggests, has the ability to query itself. Specifically, given any natural la...
langchain/docs/docs/modules/data_connection/retrievers/self_query.ipynb/0
{ "file_path": "langchain/docs/docs/modules/data_connection/retrievers/self_query.ipynb", "repo_id": "langchain", "token_count": 2494 }
193
// Code generated by mockery v2.32.4. DO NOT EDIT. package datacoord import mock "github.com/stretchr/testify/mock" // MockRWChannelStore is an autogenerated mock type for the RWChannelStore type type MockRWChannelStore struct { mock.Mock } type MockRWChannelStore_Expecter struct { mock *mock.Mock } func (_m *Mo...
milvus/internal/datacoord/mock_channel_store.go/0
{ "file_path": "milvus/internal/datacoord/mock_channel_store.go", "repo_id": "milvus", "token_count": 5029 }
1,767
import { collections } from "$lib/server/database"; import { type Actions, fail, redirect } from "@sveltejs/kit"; import { ObjectId } from "mongodb"; import { authCondition } from "$lib/server/auth"; import { base } from "$app/paths"; import { PUBLIC_ORIGIN, PUBLIC_SHARE_PREFIX } from "$env/static/public"; import { WEB...
chat-ui/src/routes/settings/assistants/[assistantId]/+page.server.ts/0
{ "file_path": "chat-ui/src/routes/settings/assistants/[assistantId]/+page.server.ts", "repo_id": "chat-ui", "token_count": 1828 }
103
<!--Copyright 2024 The HuggingFace Team. All rights reserved. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed...
diffusers/docs/source/ko/training/text2image.md/0
{ "file_path": "diffusers/docs/source/ko/training/text2image.md", "repo_id": "diffusers", "token_count": 6015 }
205
// Licensed to the LF AI & Data foundation under one // or more contributor license agreements. See the NOTICE file // distributed with this work for additional information // regarding copyright ownership. The ASF licenses this file // to you under the Apache License, Version 2.0 (the // "License"); you may not use th...
milvus/internal/distributed/querycoord/client/client.go/0
{ "file_path": "milvus/internal/distributed/querycoord/client/client.go", "repo_id": "milvus", "token_count": 6117 }
1,852
package migration import ( "context" "fmt" "strings" "sync" "time" "github.com/blang/semver/v4" clientv3 "go.etcd.io/etcd/client/v3" "go.uber.org/atomic" "github.com/milvus-io/milvus/cmd/tools/migration/backend" "github.com/milvus-io/milvus/cmd/tools/migration/configs" "github.com/milvus-io/milvus/cmd/too...
milvus/cmd/tools/migration/migration/runner.go/0
{ "file_path": "milvus/cmd/tools/migration/migration/runner.go", "repo_id": "milvus", "token_count": 2514 }
1,844
from langchain_community.document_transformers.doctran_text_extract import ( DoctranPropertyExtractor, ) __all__ = ["DoctranPropertyExtractor"]
langchain/libs/langchain/langchain/document_transformers/doctran_text_extract.py/0
{ "file_path": "langchain/libs/langchain/langchain/document_transformers/doctran_text_extract.py", "repo_id": "langchain", "token_count": 48 }
497
/* eslint-disable no-process-env */ /* eslint-disable @typescript-eslint/no-non-null-assertion */ import { test, expect } from "@jest/globals"; import { HumanMessage, AIMessage } from "@langchain/core/messages"; import { DynamoDBChatMessageHistory } from "../message/dynamodb.js"; test("Test DynamoDB message history s...
langchainjs/libs/langchain-community/src/stores/tests/dynamodb.int.test.ts/0
{ "file_path": "langchainjs/libs/langchain-community/src/stores/tests/dynamodb.int.test.ts", "repo_id": "langchainjs", "token_count": 573 }
956
import { OutputParserException } from "@langchain/core/output_parsers"; import { OutputParserArgs } from "../agent.js"; import { AgentActionOutputParser } from "../types.js"; import { FORMAT_INSTRUCTIONS } from "./prompt.js"; export const FINAL_ANSWER_ACTION = "Final Answer:"; /** * A class that extends `AgentAction...
langchainjs/langchain/src/agents/mrkl/outputParser.ts/0
{ "file_path": "langchainjs/langchain/src/agents/mrkl/outputParser.ts", "repo_id": "langchainjs", "token_count": 658 }
893
#!/usr/bin/env groovy def app="meta-migration-builder" def date="" def gitShortCommit="" pipeline { agent { kubernetes { defaultContainer 'main' yamlFile "ci/jenkins/pod/meta-builder.yaml" customWorkspace '/home/jenkins/agent/workspace' } } options { ...
milvus/ci/jenkins/MetaMigrationBuilder.groovy/0
{ "file_path": "milvus/ci/jenkins/MetaMigrationBuilder.groovy", "repo_id": "milvus", "token_count": 1049 }
1,625
poetry_requirements( name="poetry", )
llama_index/llama-index-integrations/storage/kvstore/llama-index-storage-kvstore-dynamodb/BUILD/0
{ "file_path": "llama_index/llama-index-integrations/storage/kvstore/llama-index-storage-kvstore-dynamodb/BUILD", "repo_id": "llama_index", "token_count": 18 }
1,603
<jupyter_start><jupyter_text>Self HostedLet's load the `SelfHostedEmbeddings`, `SelfHostedHuggingFaceEmbeddings`, and `SelfHostedHuggingFaceInstructEmbeddings` classes.<jupyter_code>import runhouse as rh from langchain_community.embeddings import ( SelfHostedEmbeddings, SelfHostedHuggingFaceEmbeddings, Self...
langchain/docs/docs/integrations/text_embedding/self-hosted.ipynb/0
{ "file_path": "langchain/docs/docs/integrations/text_embedding/self-hosted.ipynb", "repo_id": "langchain", "token_count": 790 }
163
""" Transforms Factory Factory methods for building image transforms for use with TIMM (PyTorch Image Models) Hacked together by / Copyright 2019, Ross Wightman """ import math from typing import Optional, Tuple, Union import torch from torchvision import transforms from timm.data.constants import IMAGENET_DEFAULT_M...
pytorch-image-models/timm/data/transforms_factory.py/0
{ "file_path": "pytorch-image-models/timm/data/transforms_factory.py", "repo_id": "pytorch-image-models", "token_count": 8112 }
389
# coding=utf-8 # Copyright 2022 The HuggingFace Team. All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless requir...
transformers/tests/models/data2vec/test_modeling_data2vec_text.py/0
{ "file_path": "transformers/tests/models/data2vec/test_modeling_data2vec_text.py", "repo_id": "transformers", "token_count": 10072 }
740
# coding=utf-8 # Copyright 2022 The HuggingFace Inc. team. All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless r...
transformers/src/transformers/models/blip/convert_blip_original_pytorch_to_hf.py/0
{ "file_path": "transformers/src/transformers/models/blip/convert_blip_original_pytorch_to_hf.py", "repo_id": "transformers", "token_count": 2804 }
627
[ "<i>Corruption discovered at the core of the Banking Clan!</i>", "<i>Reunited, Rush Clovis and Senator Amidala</i>", "<i>discover the full extent of the deception.</i>", "<i>Anakin Skywalker is sent to the rescue!</i>", "<i>He refuses to trust Clovis and asks Padm not to work with him.</i>", "<i>Determin...
langchainjs/langchain/src/document_loaders/tests/example_data/Star_Wars_The_Clone_Wars_S06E07_Crisis_at_the_Heart.json/0
{ "file_path": "langchainjs/langchain/src/document_loaders/tests/example_data/Star_Wars_The_Clone_Wars_S06E07_Crisis_at_the_Heart.json", "repo_id": "langchainjs", "token_count": 458 }
941
[build-system] build-backend = "poetry.core.masonry.api" requires = ["poetry-core"] [tool.codespell] check-filenames = true check-hidden = true skip = "*.csv,*.html,*.json,*.jsonl,*.pdf,*.txt,*.ipynb" [tool.llamahub] classes = ["MultiTenancyRAGPack"] contains_example = false import_path = "llama_index.packs.multi_ten...
llama_index/llama-index-packs/llama-index-packs-multi-tenancy-rag/pyproject.toml/0
{ "file_path": "llama_index/llama-index-packs/llama-index-packs-multi-tenancy-rag/pyproject.toml", "repo_id": "llama_index", "token_count": 676 }
1,594
#ifndef _qdq_util_cuh #define _qdq_util_cuh union half2_uint32 { uint32_t as_uint32; half2 as_half2; __device__ half2_uint32(uint32_t val) : as_uint32(val) {} __device__ half2_uint32(half2 val) : as_half2(val) {} __device__ half2_uint32() : as_uint32(0) {} }; union half_uint16 { uint16_t as_ui...
text-generation-inference/server/exllamav2_kernels/exllamav2_kernels/cuda/quant/qdq_util.cuh/0
{ "file_path": "text-generation-inference/server/exllamav2_kernels/exllamav2_kernels/cuda/quant/qdq_util.cuh", "repo_id": "text-generation-inference", "token_count": 602 }
437
<jupyter_start><jupyter_code>from datasets import load_dataset from transformers import set_seed, AutoModelForSeq2SeqLM, AutoTokenizer from peft import get_peft_model, MultitaskPromptTuningConfig, TaskType, MultitaskPromptTuningInit set_seed(42) model_name = "google/flan-t5-base" peft_config = MultitaskPromptTuningC...
peft/examples/conditional_generation/multitask_prompt_tuning.ipynb/0
{ "file_path": "peft/examples/conditional_generation/multitask_prompt_tuning.ipynb", "repo_id": "peft", "token_count": 3341 }
325
"""**Tools** are classes that an Agent uses to interact with the world. Each tool has a **description**. Agent uses the description to choose the right tool for the job. **Class hierarchy:** .. code-block:: ToolMetaclass --> BaseTool --> <name>Tool # Examples: AIPluginTool, BaseGraphQLTool ...
langchain/libs/community/langchain_community/tools/__init__.py/0
{ "file_path": "langchain/libs/community/langchain_community/tools/__init__.py", "repo_id": "langchain", "token_count": 12231 }
300
# flake8: noqa OPENAPI_PREFIX = """You are an agent designed to answer questions by making web requests to an API given the openapi spec. If the question does not seem related to the API, return I don't know. Do not make up an answer. Only use information provided by the tools to construct your response. First, find...
langchain/libs/community/langchain_community/agent_toolkits/openapi/prompt.py/0
{ "file_path": "langchain/libs/community/langchain_community/agent_toolkits/openapi/prompt.py", "repo_id": "langchain", "token_count": 413 }
213
from langchain_community.retrievers import __all__ EXPECTED_ALL = [ "AmazonKendraRetriever", "AmazonKnowledgeBasesRetriever", "ArceeRetriever", "ArxivRetriever", "AzureCognitiveSearchRetriever", "BreebsRetriever", "ChatGPTPluginRetriever", "ChaindeskRetriever", "CohereRagRetriever",...
langchain/libs/community/tests/unit_tests/retrievers/test_imports.py/0
{ "file_path": "langchain/libs/community/tests/unit_tests/retrievers/test_imports.py", "repo_id": "langchain", "token_count": 526 }
421
# neo4j-generation This template pairs LLM-based knowledge graph extraction with Neo4j AuraDB, a fully managed cloud graph database. You can create a free instance on [Neo4j Aura](https://neo4j.com/cloud/platform/aura-graph-database?utm_source=langchain&utm_content=langserve). When you initiate a free database inst...
langchain/templates/neo4j-generation/README.md/0
{ "file_path": "langchain/templates/neo4j-generation/README.md", "repo_id": "langchain", "token_count": 824 }
643
# Using LLMs ```{tip} For a list of our supported LLMs and a comparison of their functionality, check out our [LLM module guide](/module_guides/models/llms.md). ``` One of the first steps when building an LLM-based application is which LLM to use; you can also use more than one if you wish. LLMs are used at multiple...
llama_index/docs/understanding/using_llms/using_llms.md/0
{ "file_path": "llama_index/docs/understanding/using_llms/using_llms.md", "repo_id": "llama_index", "token_count": 1010 }
1,167
// Licensed to the LF AI & Data foundation under one // or more contributor license agreements. See the NOTICE file // distributed with this work for additional information // regarding copyright ownership. The ASF licenses this file // to you under the Apache License, Version 2.0 (the // "License"); you may not use th...
milvus/internal/storage/local_chunk_manager.go/0
{ "file_path": "milvus/internal/storage/local_chunk_manager.go", "repo_id": "milvus", "token_count": 2787 }
1,862
# Copyright 2024 ParaDiGMS authors and The HuggingFace Team. All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless...
diffusers/src/diffusers/schedulers/scheduling_ddim_parallel.py/0
{ "file_path": "diffusers/src/diffusers/schedulers/scheduling_ddim_parallel.py", "repo_id": "diffusers", "token_count": 13353 }
239
from typing import Any, List, Optional from langchain_core.callbacks import CallbackManagerForRetrieverRun from langchain_core.documents import Document from langchain_core.pydantic_v1 import root_validator from langchain_core.retrievers import BaseRetriever class MetalRetriever(BaseRetriever): """`Metal API` re...
langchain/libs/community/langchain_community/retrievers/metal.py/0
{ "file_path": "langchain/libs/community/langchain_community/retrievers/metal.py", "repo_id": "langchain", "token_count": 590 }
291
from llama_index.embeddings.instructor.base import InstructorEmbedding __all__ = ["InstructorEmbedding"]
llama_index/llama-index-integrations/embeddings/llama-index-embeddings-instructor/llama_index/embeddings/instructor/__init__.py/0
{ "file_path": "llama_index/llama-index-integrations/embeddings/llama-index-embeddings-instructor/llama_index/embeddings/instructor/__init__.py", "repo_id": "llama_index", "token_count": 34 }
1,189
# coding=utf-8 # Copyright 2023 HuggingFace Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or ag...
transformers/tests/tools/test_text_question_answering.py/0
{ "file_path": "transformers/tests/tools/test_text_question_answering.py", "repo_id": "transformers", "token_count": 742 }
770
from typing import Any, Callable, Dict, Optional, Sequence from llama_index.core.base.llms.types import ChatMessage, LLMMetadata from llama_index.core.callbacks import CallbackManager from llama_index.core.constants import DEFAULT_NUM_OUTPUTS, DEFAULT_TEMPERATURE from llama_index.core.llms.generic_utils import get_fro...
llama_index/llama-index-integrations/llms/llama-index-llms-everlyai/llama_index/llms/everlyai/base.py/0
{ "file_path": "llama_index/llama-index-integrations/llms/llama-index-llms-everlyai/llama_index/llms/everlyai/base.py", "repo_id": "llama_index", "token_count": 1141 }
1,294
from llama_index.core.llama_pack import BaseLlamaPack from llama_index.packs.snowflake_query_engine import SnowflakeQueryEnginePack def test_class(): names_of_base_classes = [b.__name__ for b in SnowflakeQueryEnginePack.__mro__] assert BaseLlamaPack.__name__ in names_of_base_classes
llama_index/llama-index-packs/llama-index-packs-snowflake-query-engine/tests/test_packs_snowflake_query_engine.py/0
{ "file_path": "llama_index/llama-index-packs/llama-index-packs-snowflake-query-engine/tests/test_packs_snowflake_query_engine.py", "repo_id": "llama_index", "token_count": 102 }
1,678
from langchain_core.runnables.base import ( Other, Runnable, RunnableBinding, RunnableBindingBase, RunnableEach, RunnableEachBase, RunnableGenerator, RunnableLambda, RunnableLike, RunnableParallel, RunnableSequence, RunnableSerializable, coerce_to_runnable, ) from lan...
langchain/libs/langchain/langchain/schema/runnable/base.py/0
{ "file_path": "langchain/libs/langchain/langchain/schema/runnable/base.py", "repo_id": "langchain", "token_count": 351 }
566
--- hide_table_of_contents: true sidebar_class_name: node-only --- # Apify Dataset This guide shows how to use [Apify](https://apify.com) with LangChain to load documents from an Apify Dataset. ## Overview [Apify](https://apify.com) is a cloud platform for web scraping and data extraction, which provides an [ecosys...
langchainjs/docs/core_docs/docs/integrations/document_loaders/web_loaders/apify_dataset.mdx/0
{ "file_path": "langchainjs/docs/core_docs/docs/integrations/document_loaders/web_loaders/apify_dataset.mdx", "repo_id": "langchainjs", "token_count": 679 }
733
// Licensed to the LF AI & Data foundation under one // or more contributor license agreements. See the NOTICE file // distributed with this work for additional information // regarding copyright ownership. The ASF licenses this file // to you under the Apache License, Version 2.0 (the // "License"); you may not use th...
milvus/internal/core/src/storage/Event.h/0
{ "file_path": "milvus/internal/core/src/storage/Event.h", "repo_id": "milvus", "token_count": 1350 }
1,943
<jupyter_start><jupyter_text>lakeFS>[lakeFS](https://docs.lakefs.io/) provides scalable version control over the data lake, and uses Git-like semantics to create and access those versions.This notebooks covers how to load document objects from a `lakeFS` path (whether it's an object or a prefix). Initializing the lake...
langchain/docs/docs/integrations/document_loaders/lakefs.ipynb/0
{ "file_path": "langchain/docs/docs/integrations/document_loaders/lakefs.ipynb", "repo_id": "langchain", "token_count": 402 }
106
import CodeBlock from "@theme/CodeBlock"; # Voy [Voy](https://github.com/tantaraio/voy) is a WASM vector similarity search engine written in Rust. It's supported in non-Node environments like browsers. You can use Voy as a vector store with LangChain.js. ### Install Voy import IntegrationInstallTooltip from "@mdx_c...
langchainjs/docs/core_docs/docs/integrations/vectorstores/voy.mdx/0
{ "file_path": "langchainjs/docs/core_docs/docs/integrations/vectorstores/voy.mdx", "repo_id": "langchainjs", "token_count": 190 }
723
# 🦜️🔗 Chat LangChain This repo is an implementation of a locally hosted chatbot specifically focused on question answering over the [LangChain documentation](https://python.langchain.com/). Built with [LangChain](https://github.com/langchain-ai/langchain/), [FastAPI](https://fastapi.tiangolo.com/), and [Next.js](htt...
chat-langchain/README.md/0
{ "file_path": "chat-langchain/README.md", "repo_id": "chat-langchain", "token_count": 875 }
6
import { SortXYZBlockchainLoader } from "langchain/document_loaders/web/sort_xyz_blockchain"; import { OpenAI } from "@langchain/openai"; /** * See https://docs.sort.xyz/docs/api-keys to get your free Sort API key. * See https://docs.sort.xyz for more information on the available queries. * See https://docs.sort.xy...
langchainjs/examples/src/document_loaders/sort_xyz_blockchain.ts/0
{ "file_path": "langchainjs/examples/src/document_loaders/sort_xyz_blockchain.ts", "repo_id": "langchainjs", "token_count": 928 }
831
[ { "server": "apollo", "suite_params": [ { "suite": "shards_insert_performance_sift1m.yaml", "image_type": "cpu" }, { "suite": "shards_search_performance_sift1m.yaml", "image_type": "cpu" ...
milvus/tests/benchmark/milvus_benchmark/scheduler/shards_debug.json/0
{ "file_path": "milvus/tests/benchmark/milvus_benchmark/scheduler/shards_debug.json", "repo_id": "milvus", "token_count": 225 }
1,861
<jupyter_start><jupyter_text>Airbyte Shopify >[Airbyte](https://github.com/airbytehq/airbyte) is a data integration platform for ELT pipelines from APIs, databases & files to warehouses & lakes. It has the largest catalog of ELT connectors to data warehouses and databases.This loader exposes the Shopify connector as a ...
langchain/docs/docs/integrations/document_loaders/airbyte_shopify.ipynb/0
{ "file_path": "langchain/docs/docs/integrations/document_loaders/airbyte_shopify.ipynb", "repo_id": "langchain", "token_count": 941 }
100
import { logVersion010MigrationWarning } from "../util/entrypoint_deprecation.js"; /* #__PURE__ */ logVersion010MigrationWarning({ oldEntrypointName: "chat_models/baiduwenxin", }); export * from "@langchain/community/chat_models/baiduwenxin";
langchainjs/langchain/src/chat_models/baiduwenxin.ts/0
{ "file_path": "langchainjs/langchain/src/chat_models/baiduwenxin.ts", "repo_id": "langchainjs", "token_count": 82 }
899
<jupyter_start><jupyter_text>If you're opening this Notebook on colab, you will probably need to install 🤗 Transformers and 🤗 Datasets. Uncomment the following cell and run it.<jupyter_code>#! pip install transformers #! pip install datasets #! pip install huggingface_hub<jupyter_output><empty_output><jupyter_text>If...
notebooks/examples/language_modeling-tf.ipynb/0
{ "file_path": "notebooks/examples/language_modeling-tf.ipynb", "repo_id": "notebooks", "token_count": 8823 }
322
# Streamlit > [Streamlit](https://streamlit.io/) is a faster way to build and share data apps. > `Streamlit` turns data scripts into shareable web apps in minutes. All in pure Python. No front‑end experience required. > See more examples at [streamlit.io/generative-ai](https://streamlit.io/generative-ai). ## Installa...
langchain/docs/docs/integrations/providers/streamlit.mdx/0
{ "file_path": "langchain/docs/docs/integrations/providers/streamlit.mdx", "repo_id": "langchain", "token_count": 173 }
150
from typing import Dict LLAMA_MODELS = { "meta-llama/Llama-2-7b-chat-hf": 4096, } ALL_AVAILABLE_MODELS = { **LLAMA_MODELS, } DISCONTINUED_MODELS: Dict[str, int] = {} def everlyai_modelname_to_contextsize(modelname: str) -> int: """Calculate the maximum number of tokens possible to generate for a model....
llama_index/llama-index-integrations/llms/llama-index-llms-everlyai/llama_index/llms/everlyai/utils.py/0
{ "file_path": "llama_index/llama-index-integrations/llms/llama-index-llms-everlyai/llama_index/llms/everlyai/utils.py", "repo_id": "llama_index", "token_count": 454 }
1,255
<jupyter_start><jupyter_code>%cd ../../../ import chromadb from chromadb.config import Settings client = chromadb.HttpClient("http://localhost:8000/", settings=Settings(chroma_client_auth_provider="chromadb.auth.token.TokenAuthClientProvider", ...
chroma/examples/basic_functionality/authz/authz.ipynb/0
{ "file_path": "chroma/examples/basic_functionality/authz/authz.ipynb", "repo_id": "chroma", "token_count": 308 }
40
--- sidebar_label: Ollama --- # ChatOllama [Ollama](https://ollama.ai/) allows you to run open-source large language models, such as Llama 2, locally. Ollama bundles model weights, configuration, and data into a single package, defined by a Modelfile. It optimizes setup and configuration details, including GPU usage...
langchainjs/docs/core_docs/docs/integrations/chat/ollama.mdx/0
{ "file_path": "langchainjs/docs/core_docs/docs/integrations/chat/ollama.mdx", "repo_id": "langchainjs", "token_count": 628 }
699
# coding=utf-8 # Copyright 2024 HuggingFace Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or ag...
diffusers/tests/pipelines/stable_diffusion_2/test_stable_diffusion_diffedit.py/0
{ "file_path": "diffusers/tests/pipelines/stable_diffusion_2/test_stable_diffusion_diffedit.py", "repo_id": "diffusers", "token_count": 7244 }
273
from __future__ import annotations import json import logging import time from functools import partial from typing import ( Any, AsyncIterator, Callable, Dict, Generator, Iterator, List, Optional, Sequence, Tuple, Union, ) import aiohttp import requests from langchain_core...
langchain/libs/partners/nvidia-ai-endpoints/langchain_nvidia_ai_endpoints/_common.py/0
{ "file_path": "langchain/libs/partners/nvidia-ai-endpoints/langchain_nvidia_ai_endpoints/_common.py", "repo_id": "langchain", "token_count": 8523 }
691
"""NASA Toolkit"""
langchain/libs/community/langchain_community/agent_toolkits/nasa/__init__.py/0
{ "file_path": "langchain/libs/community/langchain_community/agent_toolkits/nasa/__init__.py", "repo_id": "langchain", "token_count": 6 }
221
<!--Copyright 2021 The HuggingFace Team. All rights reserved. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed...
transformers/docs/source/en/model_doc/vit.md/0
{ "file_path": "transformers/docs/source/en/model_doc/vit.md", "repo_id": "transformers", "token_count": 2815 }
468
<jupyter_start><jupyter_text>Normalisation et prétokenization. Installez les bibliothèques 🤗 *Transformers* et 🤗 *Datasets* pour exécuter ce *notebook*.<jupyter_code>!pip install datasets transformers[sentencepiece] from transformers import AutoTokenizer tokenizer = AutoTokenizer.from_pretrained("camembert-base") p...
notebooks/course/fr/chapter6/section4.ipynb/0
{ "file_path": "notebooks/course/fr/chapter6/section4.ipynb", "repo_id": "notebooks", "token_count": 362 }
295
// Licensed to the LF AI & Data foundation under one // or more contributor license agreements. See the NOTICE file // distributed with this work for additional information // regarding copyright ownership. The ASF licenses this file // to you under the Apache License, Version 2.0 (the // "License"); you may not use th...
milvus/internal/util/importutil/binlog_parser_test.go/0
{ "file_path": "milvus/internal/util/importutil/binlog_parser_test.go", "repo_id": "milvus", "token_count": 6613 }
1,898
# Stable Diffusion text-to-image fine-tuning This extended LoRA training script was authored by [haofanwang](https://github.com/haofanwang). This is an experimental LoRA extension of [this example](https://github.com/huggingface/diffusers/blob/main/examples/text_to_image/train_text_to_image_lora.py). We further support...
diffusers/examples/research_projects/lora/README.md/0
{ "file_path": "diffusers/examples/research_projects/lora/README.md", "repo_id": "diffusers", "token_count": 1628 }
220
"""Code splitter.""" from typing import Any, Callable, List, Optional from llama_index.legacy.bridge.pydantic import Field, PrivateAttr from llama_index.legacy.callbacks.base import CallbackManager from llama_index.legacy.callbacks.schema import CBEventType, EventPayload from llama_index.legacy.node_parser.interface ...
llama_index/llama-index-legacy/llama_index/legacy/node_parser/text/code.py/0
{ "file_path": "llama_index/llama-index-legacy/llama_index/legacy/node_parser/text/code.py", "repo_id": "llama_index", "token_count": 2758 }
1,689
set -ex docker compose down -v --remove-orphans docker build --tag graphdb . docker compose up -d graphdb
langchain/libs/community/tests/integration_tests/graphs/docker-compose-ontotext-graphdb/start.sh/0
{ "file_path": "langchain/libs/community/tests/integration_tests/graphs/docker-compose-ontotext-graphdb/start.sh", "repo_id": "langchain", "token_count": 32 }
337
from chromadb.api import ServerAPI from chromadb.config import DEFAULT_DATABASE, DEFAULT_TENANT, Settings, System from chromadb.db.system import SysDB from chromadb.segment import SegmentManager, MetadataReader, VectorReader from chromadb.telemetry.opentelemetry import ( add_attributes_to_current_span, OpenTele...
chroma/chromadb/api/segment.py/0
{ "file_path": "chroma/chromadb/api/segment.py", "repo_id": "chroma", "token_count": 14917 }
11
from langchain_community.document_loaders.rocksetdb import ( RocksetLoader, ) __all__ = ["RocksetLoader"]
langchain/libs/langchain/langchain/document_loaders/rocksetdb.py/0
{ "file_path": "langchain/libs/langchain/langchain/document_loaders/rocksetdb.py", "repo_id": "langchain", "token_count": 40 }
489
# coding=utf-8 # Copyright 2022 The HuggingFace Inc. team. All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless r...
transformers/src/transformers/models/blip/configuration_blip.py/0
{ "file_path": "transformers/src/transformers/models/blip/configuration_blip.py", "repo_id": "transformers", "token_count": 6358 }
641
""" This script ports models from VQ-diffusion (https://github.com/microsoft/VQ-Diffusion) to diffusers. It currently only supports porting the ITHQ dataset. ITHQ dataset: ```sh # From the root directory of diffusers. # Download the VQVAE checkpoint $ wget https://facevcstandard.blob.core.windows.net/v-zhictang/Impr...
diffusers/scripts/convert_vq_diffusion_to_diffusers.py/0
{ "file_path": "diffusers/scripts/convert_vq_diffusion_to_diffusers.py", "repo_id": "diffusers", "token_count": 14916 }
234
<jupyter_start><jupyter_text>Stress-Testing Long Context LLMs with a Recall TaskIn this section we stress-test long context recall capabilities of GPT-4 and Claude v2. This is inspired by [Greg Kamradt's tweet](https://x.com/GregKamradt/status/1722386725635580292?s=20). Similarly, we analyze the "needle in a haystack" ...
llama_index/docs/examples/response_synthesizers/long_context_test.ipynb/0
{ "file_path": "llama_index/docs/examples/response_synthesizers/long_context_test.ipynb", "repo_id": "llama_index", "token_count": 1923 }
1,126
<!--Copyright 2024 The HuggingFace Team. All rights reserved. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed...
diffusers/docs/source/en/using-diffusers/reproducibility.md/0
{ "file_path": "diffusers/docs/source/en/using-diffusers/reproducibility.md", "repo_id": "diffusers", "token_count": 2403 }
189
from typing import Any, Optional, Sequence from llama_index.core.callbacks.base import CallbackManager from llama_index.core.indices.prompt_helper import PromptHelper from llama_index.core.prompts import BasePromptTemplate from llama_index.core.prompts.default_prompts import DEFAULT_SIMPLE_INPUT_PROMPT from llama_inde...
llama_index/llama-index-core/llama_index/core/response_synthesizers/generation.py/0
{ "file_path": "llama_index/llama-index-core/llama_index/core/response_synthesizers/generation.py", "repo_id": "llama_index", "token_count": 1335 }
1,200
import { OpenAIWhisperAudio } from "langchain/document_loaders/fs/openai_whisper_audio"; const filePath = "./src/document_loaders/example_data/test.mp3"; const loader = new OpenAIWhisperAudio(filePath); const docs = await loader.load(); console.log(docs);
langchainjs/examples/src/document_loaders/openai_whisper_audio.ts/0
{ "file_path": "langchainjs/examples/src/document_loaders/openai_whisper_audio.ts", "repo_id": "langchainjs", "token_count": 89 }
796
import { redirect } from "@sveltejs/kit"; import { getOIDCAuthorizationUrl } from "$lib/server/auth"; import { base } from "$app/paths"; import { ALTERNATIVE_REDIRECT_URLS } from "$env/static/private"; export const actions = { async default({ url, locals, request }) { const referer = request.headers.get("referer");...
chat-ui/src/routes/login/+page.server.ts/0
{ "file_path": "chat-ui/src/routes/login/+page.server.ts", "repo_id": "chat-ui", "token_count": 286 }
111
python_sources()
llama_index/llama-index-integrations/vector_stores/llama-index-vector-stores-mongodb/llama_index/vector_stores/mongodb/BUILD/0
{ "file_path": "llama_index/llama-index-integrations/vector_stores/llama-index-vector-stores-mongodb/llama_index/vector_stores/mongodb/BUILD", "repo_id": "llama_index", "token_count": 6 }
1,469
<!--Copyright 2022 The HuggingFace Team. All rights reserved. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed...
transformers/docs/source/es/tasks/language_modeling.md/0
{ "file_path": "transformers/docs/source/es/tasks/language_modeling.md", "repo_id": "transformers", "token_count": 6370 }
516
<jupyter_start><jupyter_text>MultiOn DemoThis notebook walks through an example of using LlamaIndex with MultiOn to browse the web on the users behalf.First, we import the OpenAIAgent that will control the Multion session:<jupyter_code># Set up OpenAI import openai from llama_index.agent import OpenAIAgent openai.api_...
llama_index/llama-index-integrations/tools/llama-index-tools-multion/examples/multion.ipynb/0
{ "file_path": "llama_index/llama-index-integrations/tools/llama-index-tools-multion/examples/multion.ipynb", "repo_id": "llama_index", "token_count": 1461 }
1,444
<jupyter_start><jupyter_text>In-painting pipeline for Stable Diffusion using 🧨 Diffusers This notebook shows how to do text-guided in-painting with Stable Diffusion model using 🤗 Hugging Face [🧨 Diffusers library](https://github.com/huggingface/diffusers). For a general introduction to the Stable Diffusion model pl...
notebooks/diffusers/in_painting_with_stable_diffusion_using_diffusers.ipynb/0
{ "file_path": "notebooks/diffusers/in_painting_with_stable_diffusion_using_diffusers.ipynb", "repo_id": "notebooks", "token_count": 1254 }
314
from typing import List, Tuple from langchain.agents import AgentExecutor from langchain.agents.format_scratchpad import format_to_openai_function_messages from langchain.agents.output_parsers import OpenAIFunctionsAgentOutputParser from langchain.prompts import ChatPromptTemplate, MessagesPlaceholder from langchain.p...
langchain/templates/neo4j-semantic-layer/neo4j_semantic_layer/agent.py/0
{ "file_path": "langchain/templates/neo4j-semantic-layer/neo4j_semantic_layer/agent.py", "repo_id": "langchain", "token_count": 876 }
671
package broker import ( "context" "github.com/samber/lo" "go.uber.org/zap" "github.com/milvus-io/milvus-proto/go-api/v2/commonpb" "github.com/milvus-io/milvus-proto/go-api/v2/msgpb" "github.com/milvus-io/milvus/internal/metastore/kv/binlog" "github.com/milvus-io/milvus/internal/proto/datapb" "github.com/milv...
milvus/internal/datanode/broker/datacoord.go/0
{ "file_path": "milvus/internal/datanode/broker/datacoord.go", "repo_id": "milvus", "token_count": 1923 }
1,968
--- sidebar_position: 2 --- # How to import DocCardList from "@theme/DocCardList"; <DocCardList />
langchain/docs/docs/expression_language/how_to/index.mdx/0
{ "file_path": "langchain/docs/docs/expression_language/how_to/index.mdx", "repo_id": "langchain", "token_count": 36 }
85
import { UseFormReturn } from "react-hook-form"; export type FormValues = { evalQuestionsCount: number; chunkSize: number; overlap: number; splitMethod: string; embeddingAlgorithm: string; model: string; retriever: string; gradingPrompt: string; numNeighbors: number; files: any[]; }; export type F...
auto-evaluator/nextjs/utils/types.ts/0
{ "file_path": "auto-evaluator/nextjs/utils/types.ts", "repo_id": "auto-evaluator", "token_count": 309 }
3
# flake8: noqa # There's no way to ignore "F401 '...' imported but unused" warnings in this # module, but to preserve other warnings. So, don't check this module at all. # Copyright 2023 The HuggingFace Team. All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use thi...
transformers/src/transformers/models/tvlt/__init__.py/0
{ "file_path": "transformers/src/transformers/models/tvlt/__init__.py", "repo_id": "transformers", "token_count": 1013 }
688
// eslint-disable-next-line @typescript-eslint/no-explicit-any export type LoadValues = Record<string, any>; export type FileLoader<T> = ( text: string, filePath: string, values: LoadValues ) => Promise<T>; export const loadFromFile = async <T>( uri: string, loader: FileLoader<T>, values: LoadValues = {} ...
langchainjs/langchain/src/util/load.ts/0
{ "file_path": "langchainjs/langchain/src/util/load.ts", "repo_id": "langchainjs", "token_count": 215 }
1,028
from llama_index.core.vector_stores.types import VectorStore from llama_index.vector_stores.opensearch import OpensearchVectorStore def test_class(): names_of_base_classes = [b.__name__ for b in OpensearchVectorStore.__mro__] assert VectorStore.__name__ in names_of_base_classes
llama_index/llama-index-integrations/vector_stores/llama-index-vector-stores-opensearch/tests/test_vector_stores_opensearch.py/0
{ "file_path": "llama_index/llama-index-integrations/vector_stores/llama-index-vector-stores-opensearch/tests/test_vector_stores_opensearch.py", "repo_id": "llama_index", "token_count": 95 }
1,530
<jupyter_start><jupyter_text>Partial prompt templatesLike other methods, it can make sense to "partial" a prompt template - e.g. pass in a subset of the required values, as to create a new prompt template which expects only the remaining subset of values.LangChain supports this in two ways:1. Partial formatting with st...
langchain/docs/docs/modules/model_io/prompts/partial.ipynb/0
{ "file_path": "langchain/docs/docs/modules/model_io/prompts/partial.ipynb", "repo_id": "langchain", "token_count": 859 }
196
/** @type {import('ts-jest').JestConfigWithTsJest} */ module.exports = { preset: "ts-jest/presets/default-esm", testEnvironment: "node", modulePathIgnorePatterns: ["dist/"], moduleNameMapper: { "^(\\.{1,2}/.*)\\.js$": "$1", }, transform: { "^.+\\.m?[tj]sx?$": ["ts-jest", { useESM: true }], }, se...
langsmith-sdk/js/jest.config.cjs/0
{ "file_path": "langsmith-sdk/js/jest.config.cjs", "repo_id": "langsmith-sdk", "token_count": 166 }
1,144
// Licensed to the LF AI & Data foundation under one // or more contributor license agreements. See the NOTICE file // distributed with this work for additional information // regarding copyright ownership. The ASF licenses this file // to you under the Apache License, Version 2.0 (the // "License"); you may not use th...
milvus/internal/indexnode/indexnode_test.go/0
{ "file_path": "milvus/internal/indexnode/indexnode_test.go", "repo_id": "milvus", "token_count": 7519 }
1,714
// Licensed to the LF AI & Data foundation under one // or more contributor license agreements. See the NOTICE file // distributed with this work for additional information // regarding copyright ownership. The ASF licenses this file // to you under the Apache License, Version 2.0 (the // "License"); you may not use th...
milvus/internal/querycoordv2/checkers/util.go/0
{ "file_path": "milvus/internal/querycoordv2/checkers/util.go", "repo_id": "milvus", "token_count": 874 }
1,894
from llama_index.vector_stores.faiss.base import FaissVectorStore __all__ = ["FaissVectorStore"]
llama_index/llama-index-integrations/vector_stores/llama-index-vector-stores-faiss/llama_index/vector_stores/faiss/__init__.py/0
{ "file_path": "llama_index/llama-index-integrations/vector_stores/llama-index-vector-stores-faiss/llama_index/vector_stores/faiss/__init__.py", "repo_id": "llama_index", "token_count": 32 }
1,524
from typing import Any, List from langchain_core.embeddings import Embeddings from langchain_core.pydantic_v1 import BaseModel, Extra DEFAULT_MODEL_URL = "https://tfhub.dev/google/universal-sentence-encoder-multilingual/3" class TensorflowHubEmbeddings(BaseModel, Embeddings): """TensorflowHub embedding models. ...
langchain/libs/community/langchain_community/embeddings/tensorflow_hub.py/0
{ "file_path": "langchain/libs/community/langchain_community/embeddings/tensorflow_hub.py", "repo_id": "langchain", "token_count": 1041 }
273
from langchain_community.chat_message_histories.redis import RedisChatMessageHistory __all__ = ["RedisChatMessageHistory"]
langchain/libs/langchain/langchain/memory/chat_message_histories/redis.py/0
{ "file_path": "langchain/libs/langchain/langchain/memory/chat_message_histories/redis.py", "repo_id": "langchain", "token_count": 35 }
570