ragV98 commited on
Commit
6848e0a
Β·
1 Parent(s): e323ca3

removing changes

Browse files
Files changed (1) hide show
  1. components/generators/daily_feed.py +0 -18
components/generators/daily_feed.py CHANGED
@@ -4,27 +4,9 @@ import redis
4
  from typing import List, Dict
5
  from llama_index.core import VectorStoreIndex, StorageContext
6
  from llama_index.core.query_engine import RetrieverQueryEngine
7
- from llama_index.llms.base import LLM, LLMMetadata
8
- from llama_index.core.llms import CompletionResponse
9
- from llama_index.core.settings import Settings
10
  from components.LLMs.Mistral import call_mistral
11
  from components.indexers.news_indexer import get_upstash_vector_store
12
 
13
- # βœ… Dummy LLM config to allow higher context window in LlamaIndex
14
- class DummyLLM(LLM):
15
- def complete(self, prompt: str, **kwargs) -> CompletionResponse:
16
- return CompletionResponse(text="")
17
-
18
- @property
19
- def metadata(self) -> LLMMetadata:
20
- return LLMMetadata(
21
- context_window=8192,
22
- num_output=1024,
23
- is_chat_model=False
24
- )
25
-
26
- Settings.llm = DummyLLM()
27
-
28
  # πŸ” Environment variables
29
  REDIS_URL = os.environ.get("UPSTASH_REDIS_URL", "redis://localhost:6379")
30
  REDIS_KEY = os.environ.get("UPSTASH_REDIS_TOKEN")
 
4
  from typing import List, Dict
5
  from llama_index.core import VectorStoreIndex, StorageContext
6
  from llama_index.core.query_engine import RetrieverQueryEngine
 
 
 
7
  from components.LLMs.Mistral import call_mistral
8
  from components.indexers.news_indexer import get_upstash_vector_store
9
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
10
  # πŸ” Environment variables
11
  REDIS_URL = os.environ.get("UPSTASH_REDIS_URL", "redis://localhost:6379")
12
  REDIS_KEY = os.environ.get("UPSTASH_REDIS_TOKEN")