IntelLabs / fastRAG

Efficient Retrieval Augmentation and Generation Framework
Apache License 2.0
1.09k stars 93 forks source link

Connection error when running fastrag.rest_api_application #46

Open linhkid opened 2 months ago

linhkid commented 2 months ago

I ran this separately just to test the fastRAG pipeline

python -m fastrag.rest_api.application --config=config/my_config.yaml --app_type qa

The output looks like this

e torch.utils._pytree.register_pytree_node instead. _torch_pytree._register_pytree_node( config.json: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 794/794 [00:00<00:00, 353kB/s] pytorch_model.bin: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 90.9M/90.9M [00:09<00:00, 9.75MB/s] tokenizer_config.json: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 316/316 [00:00<00:00, 143kB/s] vocab.txt: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 232k/232k [00:00<00:00, 482kB/s] special_tokens_map.json: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 112/112 [00:00<00:00, 41.6kB/s] The model 'FusionInDecoderForConditionalGeneration' is not supported for text2text-generation. Supported models are ['BartForConditionalGeneration', 'BigBirdPegasusForConditionalGeneration', 'BlenderbotForConditionalGeneration', 'BlenderbotSmallForConditionalGeneration', 'EncoderDecoderModel', 'FSMTForConditionalGeneration', 'GPTSanJapaneseForConditionalGeneration', 'LEDForConditionalGeneration', 'LongT5ForConditionalGeneration', 'M2M100ForConditionalGeneration', 'MarianMTModel', 'MBartForConditionalGeneration', 'MT5ForConditionalGeneration', 'MvpForConditionalGeneration', 'NllbMoeForConditionalGeneration', 'PegasusForConditionalGeneration', 'PegasusXForConditionalGeneration', 'PLBartForConditionalGeneration', 'ProphetNetForConditionalGeneration', 'SeamlessM4TForTextToText', 'SwitchTransformersForConditionalGeneration', 'T5ForConditionalGeneration', 'UMT5ForConditionalGeneration', 'XLMProphetNetForConditionalGeneration']. INFO: Started server process [67999] INFO: Waiting for application startup. INFO: Application startup complete. INFO: Uvicorn running on http://0.0.0.0:8000 (Press CTRL+C to quit) INFO: 127.0.0.1:65140 - "GET /status HTTP/1.1" 404 Not Found

When I turn on the UI separately it will return 404 Not Found on the endpoint, and connection error displays as below. Any help? But running on notebooks is absolutely fine.

Screenshot 2024-04-14 at 12 39 30 PM
danielfleischer commented 2 months ago

Hi, how do you call the UI?

linhkid commented 2 months ago

I just run the python -m streamlit run fastrag/ui/webapp.py command

danielfleischer commented 2 months ago

Maybe the port is used by something else? try to see if the server works by calling curl localhost:8000/status to see if it's a server or an UI issue.

linhkid commented 2 months ago

The port wasn't used by something else, I have checked it. It's ok, I will try to figure out on my own some more.

danielfleischer commented 1 month ago

Try setting export ROOT_PATH="".