├── .gitattributes ├── .github ├── CODEOWNERS ├── ISSUE_TEMPLATE │ ├── 1_bug_template.yml │ ├── 2_feature_template.yml │ └── config.yml ├── code_spell_ignore.txt ├── env │ └── _build_image.sh ├── license_template.txt ├── pull_request_template.md └── workflows │ ├── _build_comps_base_image.yml │ ├── _build_image.yml │ ├── _example-workflow.yml │ ├── _get-image-list.yml │ ├── _get-test-matrix.yml │ ├── _gmc-e2e.yml │ ├── _gmc-workflow.yml │ ├── _helm-e2e.yml │ ├── _run-docker-compose.yml │ ├── check-online-doc-build.yml │ ├── daily-update-vllm-version.yml │ ├── daily_check_issue_and_pr.yml │ ├── docker │ └── code-scan.dockerfile │ ├── dockerhub-description.yml │ ├── manual-docker-clean.yml │ ├── manual-docker-publish.yml │ ├── manual-docker-scan.yml │ ├── manual-example-workflow.yml │ ├── manual-freeze-tag.yml │ ├── manual-image-build.yml │ ├── manual-reset-local-registry.yml │ ├── mix-trellix.yml │ ├── nightly-docker-build-publish.yml │ ├── pr-chart-e2e.yml │ ├── pr-check-duplicated-image.yml │ ├── pr-code-scan.yml │ ├── pr-dependency-review.yml │ ├── pr-docker-compose-e2e.yml │ ├── pr-dockerfile-path-and-build-yaml-scan.yml │ ├── pr-gmc-e2e.yaml.disabled │ ├── pr-link-path-scan.yml │ ├── push-image-build.yml │ ├── push-images-path-detection.yml │ ├── push-infra-issue-creation.yml │ ├── scorecard.yml │ ├── scripts │ ├── change_color │ ├── check-name-agreement.py │ ├── check_duplicated_image.py │ ├── codeScan │ │ ├── bandit.sh │ │ ├── hadolint.sh │ │ └── trellix.sh │ ├── docker_compose_clean_up.sh │ ├── get_test_matrix.sh │ ├── k8s-utils.sh │ └── update_images_tag.sh │ ├── weekly-example-test.yml │ └── weekly-update-images.yml ├── .gitignore ├── .pre-commit-config.yaml ├── .prettierignore ├── .set_env.sh ├── AgentQnA ├── README.md ├── assets │ └── img │ │ ├── agent_qna_arch.png │ │ ├── agent_ui.png │ │ ├── agent_ui_result.png │ │ ├── opea-agent-setting.png │ │ └── opea-agent-test.png ├── docker_compose │ ├── amd │ │ └── gpu │ │ │ └── rocm │ │ │ ├── README.md │ │ │ ├── compose.yaml │ │ │ ├── compose_vllm.yaml │ │ │ ├── launch_agent_service_tgi_rocm.sh │ │ │ ├── launch_agent_service_vllm_rocm.sh │ │ │ ├── stop_agent_service_tgi_rocm.sh │ │ │ └── stop_agent_service_vllm_rocm.sh │ └── intel │ │ ├── cpu │ │ └── xeon │ │ │ ├── README.md │ │ │ ├── compose_openai.yaml │ │ │ ├── compose_remote.yaml │ │ │ └── set_env.sh │ │ └── hpu │ │ └── gaudi │ │ ├── README.md │ │ ├── compose.telemetry.yaml │ │ ├── compose.webtool.yaml │ │ ├── compose.yaml │ │ ├── grafana │ │ ├── dashboards │ │ │ └── download_opea_dashboard.sh │ │ └── provisioning │ │ │ ├── dashboards │ │ │ └── local.yaml │ │ │ └── datasources │ │ │ └── datasource.yml │ │ ├── prometheus.yaml │ │ ├── set_env.sh │ │ └── tgi_gaudi.yaml ├── docker_image_build │ ├── .README │ └── build.yaml ├── example_data │ └── test_docs_music.jsonl ├── kubernetes │ └── helm │ │ ├── README.md │ │ ├── cpu-values.yaml │ │ └── gaudi-values.yaml ├── retrieval_tool │ ├── README.md │ ├── index_data.py │ ├── launch_retrieval_tool.sh │ └── run_ingest_data.sh ├── tests │ ├── _test_compose_openai_on_xeon.sh │ ├── sql_agent_test │ │ ├── run_data_split.sh │ │ └── split_data.py │ ├── step1_build_images.sh │ ├── step2_start_retrieval_tool.sh │ ├── step2_start_retrieval_tool_rocm_vllm.sh │ ├── step3_ingest_data_and_validate_retrieval.sh │ ├── step3_ingest_data_and_validate_retrieval_rocm_vllm.sh │ ├── step4_launch_and_validate_agent_gaudi.sh │ ├── step4_launch_and_validate_agent_openai.sh │ ├── step4_launch_and_validate_agent_rocm_vllm.sh │ ├── step4a_launch_and_validate_agent_tgi_on_rocm.sh │ ├── test.py │ ├── test_compose_on_gaudi.sh │ ├── test_compose_on_rocm.sh │ └── test_compose_vllm_on_rocm.sh ├── tools │ ├── pycragapi.py │ ├── supervisor_agent_tools.yaml │ ├── supervisor_agent_webtools.yaml │ ├── tools.py │ ├── worker_agent_tools.py │ └── worker_agent_tools.yaml └── ui │ ├── docker │ └── Dockerfile │ └── open_webui_patches │ ├── 0001-compatible-opea-agent-tool-content.patch │ ├── 0002-update-agent-icloud-upload-feature.patch │ ├── 0003-update-build-script.patch │ ├── 0004-enhance-tool-formating.patch │ └── 0005-fix-tool-call-typo.patch ├── AudioQnA ├── Dockerfile ├── Dockerfile.multilang ├── README.md ├── README_miscellaneous.md ├── assets │ └── img │ │ ├── audio_ui.png │ │ ├── audio_ui_record.png │ │ └── audioqna.jpg ├── audioqna.py ├── audioqna_multilang.py ├── benchmark │ ├── accuracy │ │ ├── README.md │ │ ├── local_eval.py │ │ ├── online_eval.py │ │ ├── requirements.txt │ │ └── run_acc.sh │ └── performance │ │ ├── README.md │ │ ├── benchmark.sh │ │ └── benchmark.yaml ├── docker_compose │ ├── amd │ │ └── gpu │ │ │ └── rocm │ │ │ ├── README.md │ │ │ ├── compose.yaml │ │ │ ├── compose_vllm.yaml │ │ │ ├── set_env.sh │ │ │ └── set_env_vllm.sh │ └── intel │ │ ├── cpu │ │ └── xeon │ │ │ ├── README.md │ │ │ ├── README_vllm.md │ │ │ ├── compose.yaml │ │ │ ├── compose_multilang.yaml │ │ │ ├── compose_tgi.yaml │ │ │ └── set_env.sh │ │ └── hpu │ │ └── gaudi │ │ ├── README.md │ │ ├── compose.yaml │ │ ├── compose_tgi.yaml │ │ └── set_env.sh ├── docker_image_build │ └── build.yaml ├── kubernetes │ ├── gmc │ │ ├── README.md │ │ ├── audioQnA_gaudi.yaml │ │ └── audioQnA_xeon.yaml │ └── helm │ │ ├── README.md │ │ ├── cpu-multilang-values.yaml │ │ ├── cpu-tgi-values.yaml │ │ ├── cpu-values.yaml │ │ ├── gaudi-tgi-values.yaml │ │ └── gaudi-values.yaml ├── tests │ ├── README.md │ ├── test_compose_multilang_on_xeon.sh │ ├── test_compose_on_gaudi.sh │ ├── test_compose_on_rocm.sh │ ├── test_compose_on_xeon.sh │ ├── test_compose_tgi_on_gaudi.sh │ ├── test_compose_tgi_on_xeon.sh │ ├── test_compose_vllm_on_rocm.sh │ ├── test_gmc_on_gaudi.sh │ └── test_gmc_on_xeon.sh └── ui │ ├── docker │ └── Dockerfile │ └── svelte │ ├── .editorconfig │ ├── .env │ ├── .eslintignore │ ├── .eslintrc.cjs │ ├── .prettierignore │ ├── .prettierrc │ ├── README.md │ ├── package.json │ ├── postcss.config.cjs │ ├── src │ ├── app.d.ts │ ├── app.html │ ├── app.postcss │ ├── lib │ │ ├── assets │ │ │ └── icons │ │ │ │ ├── png │ │ │ │ ├── audio1.png │ │ │ │ └── audio2.png │ │ │ │ ├── svelte │ │ │ │ ├── arrow-path-icon.svelte │ │ │ │ ├── assistant.svelte │ │ │ │ ├── chat-bubble-left-icon.svelte │ │ │ │ ├── chat.svelte │ │ │ │ ├── check-icon.svelte │ │ │ │ ├── intel.svelte │ │ │ │ ├── loading-button-spinner-icon.svelte │ │ │ │ ├── message-avatar.svelte │ │ │ │ ├── plus-icon.svelte │ │ │ │ ├── portrait.svelte │ │ │ │ ├── voice-button.svelte │ │ │ │ └── x-mark-icon.svelte │ │ │ │ └── svg │ │ │ │ ├── 1.svg │ │ │ │ ├── 2.svg │ │ │ │ ├── 3.svg │ │ │ │ ├── 4.svg │ │ │ │ ├── 5.svg │ │ │ │ ├── Voice-Wave-Dark.svg │ │ │ │ ├── stop-recording.svg │ │ │ │ ├── upload.svg │ │ │ │ ├── voice.svg │ │ │ │ ├── voiceOff.svg │ │ │ │ └── voiceOn.svg │ │ ├── common │ │ │ ├── sse.d.ts │ │ │ └── timediff.ts │ │ ├── components │ │ │ ├── layout.svelte │ │ │ ├── shared │ │ │ │ ├── shared-utils.ts │ │ │ │ ├── shared.store.ts │ │ │ │ └── shared.type.ts │ │ │ ├── talkbot │ │ │ │ ├── store.ts │ │ │ │ ├── voice-button.svelte │ │ │ │ └── voice-wave.svelte │ │ │ └── topnavigation │ │ │ │ └── Index.svelte │ │ └── modules │ │ │ └── chat │ │ │ ├── chat-audio.svelte │ │ │ ├── chat-message.svelte │ │ │ ├── message-timer.svelte │ │ │ └── network.ts │ └── routes │ │ ├── +layout.svelte │ │ └── +page.svelte │ ├── static │ └── favicon.png │ ├── svelte.config.js │ ├── tailwind.config.cjs │ ├── tsconfig.json │ └── vite.config.ts ├── AvatarChatbot ├── .gitignore ├── Dockerfile ├── README.md ├── assets │ ├── audio │ │ ├── eg3_ref.wav │ │ ├── sample_minecraft.json │ │ ├── sample_question.json │ │ └── sample_whoareyou.json │ ├── img │ │ ├── UI.png │ │ ├── avatar1.jpg │ │ ├── avatar2.jpg │ │ ├── avatar3.png │ │ ├── avatar4.png │ │ ├── avatar5.png │ │ ├── avatar6.png │ │ ├── design.png │ │ ├── flowchart.png │ │ ├── gaudi.png │ │ ├── opea_gh_qr.png │ │ ├── opea_qr.png │ │ └── xeon.jpg │ └── outputs │ │ ├── result_max_tokens_1024.mp4 │ │ └── result_max_tokens_64.mp4 ├── avatarchatbot.py ├── docker_compose │ ├── amd │ │ └── gpu │ │ │ └── rocm │ │ │ ├── README.md │ │ │ ├── compose.yaml │ │ │ └── set_env.sh │ └── intel │ │ ├── cpu │ │ └── xeon │ │ │ ├── README.md │ │ │ ├── compose.yaml │ │ │ └── set_env.sh │ │ └── hpu │ │ └── gaudi │ │ ├── README.md │ │ ├── compose.yaml │ │ └── set_env.sh ├── docker_image_build │ └── build.yaml ├── tests │ ├── README.md │ ├── test_compose_on_gaudi.sh │ ├── test_compose_on_rocm.sh │ └── test_compose_on_xeon.sh └── ui │ └── gradio │ └── app_gradio_demo_avatarchatbot.py ├── ChatQnA ├── Dockerfile ├── README.md ├── README_miscellaneous.md ├── assets │ └── img │ │ ├── chat_ui_init.png │ │ ├── chat_ui_response.png │ │ ├── chat_ui_upload.png │ │ ├── chatqna_architecture.png │ │ ├── chatqna_dashboards.png │ │ ├── chatqna_flow_chart.png │ │ ├── conversation_ui_init.png │ │ ├── conversation_ui_response.png │ │ ├── conversation_ui_upload.png │ │ ├── tgi_dashboard.png │ │ ├── ui-result-page-faqgen.png │ │ ├── ui-result-page.png │ │ └── ui-starting-page.png ├── benchmark │ ├── accuracy │ │ ├── README.md │ │ ├── eval_crud.py │ │ ├── eval_multihop.py │ │ ├── process_crud_dataset.py │ │ └── run_acc.sh │ ├── accuracy_faqgen │ │ ├── README.md │ │ ├── evaluate.py │ │ ├── generate_FAQ.py │ │ ├── get_context.py │ │ ├── launch_tgi.sh │ │ ├── post_process_FAQ.py │ │ └── run_acc.sh │ └── performance_faqgen │ │ ├── README.md │ │ ├── benchmark.sh │ │ └── benchmark.yaml ├── benchmark_chatqna.yaml ├── chatqna.py ├── chatqna_wrapper.py ├── docker_compose │ ├── amd │ │ └── gpu │ │ │ └── rocm │ │ │ ├── README.md │ │ │ ├── compose.yaml │ │ │ ├── compose_faqgen.yaml │ │ │ ├── compose_faqgen_vllm.yaml │ │ │ ├── compose_vllm.yaml │ │ │ ├── set_env.sh │ │ │ ├── set_env_faqgen.sh │ │ │ ├── set_env_faqgen_vllm.sh │ │ │ └── set_env_vllm.sh │ ├── intel │ │ ├── cpu │ │ │ ├── aipc │ │ │ │ ├── README.md │ │ │ │ ├── compose.yaml │ │ │ │ └── set_env.sh │ │ │ └── xeon │ │ │ │ ├── README.md │ │ │ │ ├── README_faqgen.md │ │ │ │ ├── README_mariadb.md │ │ │ │ ├── README_pinecone.md │ │ │ │ ├── README_qdrant.md │ │ │ │ ├── compose.telemetry.yaml │ │ │ │ ├── compose.yaml │ │ │ │ ├── compose_faqgen.yaml │ │ │ │ ├── compose_faqgen_tgi.yaml │ │ │ │ ├── compose_mariadb.yaml │ │ │ │ ├── compose_milvus.yaml │ │ │ │ ├── compose_pinecone.yaml │ │ │ │ ├── compose_qdrant.yaml │ │ │ │ ├── compose_remote.yaml │ │ │ │ ├── compose_tgi.telemetry.yaml │ │ │ │ ├── compose_tgi.yaml │ │ │ │ ├── compose_without_rerank.yaml │ │ │ │ ├── grafana │ │ │ │ ├── dashboards │ │ │ │ │ └── download_opea_dashboard.sh │ │ │ │ └── provisioning │ │ │ │ │ ├── dashboards │ │ │ │ │ └── local.yaml │ │ │ │ │ └── datasources │ │ │ │ │ └── datasource.yml │ │ │ │ ├── milvus.yaml │ │ │ │ ├── prometheus.yaml │ │ │ │ ├── set_env.sh │ │ │ │ └── set_env_mariadb.sh │ │ └── hpu │ │ │ └── gaudi │ │ │ ├── README.md │ │ │ ├── compose.telemetry.yaml │ │ │ ├── compose.yaml │ │ │ ├── compose_faqgen.yaml │ │ │ ├── compose_faqgen_tgi.yaml │ │ │ ├── compose_guardrails.yaml │ │ │ ├── compose_tgi.telemetry.yaml │ │ │ ├── compose_tgi.yaml │ │ │ ├── compose_without_rerank.yaml │ │ │ ├── grafana │ │ │ ├── dashboards │ │ │ │ └── download_opea_dashboard.sh │ │ │ └── provisioning │ │ │ │ ├── dashboards │ │ │ │ └── local.yaml │ │ │ │ └── datasources │ │ │ │ └── datasource.yml │ │ │ ├── how_to_validate_service.md │ │ │ ├── prometheus.yaml │ │ │ ├── set_env.sh │ │ │ └── set_env_faqgen.sh │ └── nvidia │ │ └── gpu │ │ ├── README.md │ │ ├── compose.yaml │ │ └── set_env.sh ├── docker_image_build │ └── build.yaml ├── entrypoint.sh ├── kubernetes │ ├── gmc │ │ ├── README.md │ │ ├── chatQnA_dataprep_gaudi.yaml │ │ ├── chatQnA_dataprep_xeon.yaml │ │ ├── chatQnA_gaudi.yaml │ │ ├── chatQnA_switch_gaudi.yaml │ │ ├── chatQnA_switch_xeon.yaml │ │ └── chatQnA_xeon.yaml │ └── helm │ │ ├── README.md │ │ ├── cpu-milvus-values.yaml │ │ ├── cpu-qdrant-values.yaml │ │ ├── cpu-tgi-values.yaml │ │ ├── cpu-values.yaml │ │ ├── faqgen-cpu-tgi-values.yaml │ │ ├── faqgen-cpu-values.yaml │ │ ├── faqgen-gaudi-tgi-values.yaml │ │ ├── faqgen-gaudi-values.yaml │ │ ├── gaudi-tgi-values.yaml │ │ ├── gaudi-values.yaml │ │ ├── guardrails-gaudi-values.yaml │ │ └── norerank-values.yaml ├── tests │ ├── README.md │ ├── test_compose_faqgen_on_gaudi.sh │ ├── test_compose_faqgen_on_rocm.sh │ ├── test_compose_faqgen_on_xeon.sh │ ├── test_compose_faqgen_tgi_on_gaudi.sh │ ├── test_compose_faqgen_tgi_on_xeon.sh │ ├── test_compose_faqgen_vllm_on_rocm.sh │ ├── test_compose_guardrails_on_gaudi.sh │ ├── test_compose_mariadb_on_xeon.sh │ ├── test_compose_milvus_on_xeon.sh │ ├── test_compose_on_gaudi.sh │ ├── test_compose_on_rocm.sh │ ├── test_compose_on_xeon.sh │ ├── test_compose_pinecone_on_xeon.sh │ ├── test_compose_qdrant_on_xeon.sh │ ├── test_compose_tgi_on_gaudi.sh │ ├── test_compose_tgi_on_xeon.sh │ ├── test_compose_vllm_on_rocm.sh │ ├── test_compose_without_rerank_on_gaudi.sh │ ├── test_compose_without_rerank_on_xeon.sh │ ├── test_gmc_on_gaudi.sh │ └── test_gmc_on_xeon.sh └── ui │ ├── docker │ ├── Dockerfile │ └── Dockerfile.react │ ├── react │ ├── .env │ ├── .env.production │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── env.sh │ ├── index.html │ ├── nginx.conf │ ├── package.json │ ├── postcss.config.cjs │ ├── public │ │ └── vite.svg │ ├── src │ │ ├── App.scss │ │ ├── App.tsx │ │ ├── __tests__ │ │ │ └── util.test.ts │ │ ├── assets │ │ │ ├── opea-icon-black.svg │ │ │ ├── opea-icon-color.svg │ │ │ └── react.svg │ │ ├── common │ │ │ ├── client.ts │ │ │ └── util.ts │ │ ├── components │ │ │ ├── Conversation │ │ │ │ ├── Conversation.tsx │ │ │ │ ├── ConversationSideBar.tsx │ │ │ │ ├── DataSource.tsx │ │ │ │ └── conversation.module.scss │ │ │ ├── Message │ │ │ │ ├── conversationMessage.module.scss │ │ │ │ └── conversationMessage.tsx │ │ │ ├── UserInfoModal │ │ │ │ └── UserInfoModal.tsx │ │ │ └── sidebar │ │ │ │ ├── sidebar.module.scss │ │ │ │ └── sidebar.tsx │ │ ├── config.ts │ │ ├── index.scss │ │ ├── main.tsx │ │ ├── redux │ │ │ ├── Conversation │ │ │ │ ├── Conversation.ts │ │ │ │ └── ConversationSlice.ts │ │ │ ├── User │ │ │ │ ├── user.d.ts │ │ │ │ └── userSlice.ts │ │ │ ├── store.ts │ │ │ └── thunkUtil.ts │ │ ├── styles │ │ │ ├── components │ │ │ │ ├── _context.scss │ │ │ │ ├── _sidebar.scss │ │ │ │ ├── content.scss │ │ │ │ └── context.module.scss │ │ │ ├── layout │ │ │ │ ├── _basics.scss │ │ │ │ └── _flex.scss │ │ │ └── styles.scss │ │ └── vite-env.d.ts │ ├── tsconfig.json │ ├── tsconfig.node.json │ └── vite.config.ts │ └── svelte │ ├── .editorconfig │ ├── .env │ ├── .eslintignore │ ├── .eslintrc.cjs │ ├── .prettierignore │ ├── .prettierrc │ ├── README.md │ ├── package.json │ ├── playwright.config.ts │ ├── postcss.config.cjs │ ├── src │ ├── app.d.ts │ ├── app.html │ ├── app.postcss │ ├── lib │ │ ├── assets │ │ │ ├── DocManagement │ │ │ │ ├── LinkfolderIcon.svelte │ │ │ │ ├── fileIcon.svelte │ │ │ │ └── folderIcon.svelte │ │ │ ├── avatar │ │ │ │ └── svelte │ │ │ │ │ └── Delete.svelte │ │ │ ├── chat │ │ │ │ └── svelte │ │ │ │ │ ├── Assistant.svelte │ │ │ │ │ ├── PaperAirplane.svelte │ │ │ │ │ └── PersonOutlined.svelte │ │ │ ├── layout │ │ │ │ └── css │ │ │ │ │ └── driver.css │ │ │ ├── upload │ │ │ │ ├── deleteIcon.svelte │ │ │ │ ├── loading-button.svelte │ │ │ │ ├── next.svelte │ │ │ │ ├── no-file.svelte │ │ │ │ └── previous.svelte │ │ │ └── voice │ │ │ │ └── svg │ │ │ │ ├── paste.svg │ │ │ │ └── uploadFile.svg │ │ ├── modules │ │ │ ├── chat │ │ │ │ ├── ChatMessage.svelte │ │ │ │ ├── MessageAvatar.svelte │ │ │ │ └── MessageTimer.svelte │ │ │ └── frame │ │ │ │ └── Layout.svelte │ │ ├── network │ │ │ ├── chat │ │ │ │ └── Network.ts │ │ │ └── upload │ │ │ │ └── Network.ts │ │ └── shared │ │ │ ├── Utils.ts │ │ │ ├── components │ │ │ ├── chat │ │ │ │ └── gallery.svelte │ │ │ ├── doc_management │ │ │ │ ├── docCard.svelte │ │ │ │ └── treeView │ │ │ │ │ ├── svelte-tree.svelte │ │ │ │ │ ├── tree-branch.svelte │ │ │ │ │ └── tree-node.svelte │ │ │ ├── loading │ │ │ │ ├── Loading.svelte │ │ │ │ └── Spinner.svelte │ │ │ ├── scrollbar │ │ │ │ └── Scrollbar.svelte │ │ │ └── upload │ │ │ │ ├── PasteKnowledge.svelte │ │ │ │ ├── upload-knowledge.svelte │ │ │ │ └── uploadFile.svelte │ │ │ ├── constant │ │ │ └── Interface.ts │ │ │ └── stores │ │ │ └── common │ │ │ └── Store.ts │ └── routes │ │ ├── +layout.svelte │ │ ├── +page.svelte │ │ └── +page.ts │ ├── static │ └── favicon.png │ ├── svelte.config.js │ ├── tailwind.config.cjs │ ├── tests │ ├── chatQnA.spec.ts │ └── test_file.txt │ ├── tsconfig.json │ └── vite.config.ts ├── CodeGen ├── Dockerfile ├── README.md ├── assets │ └── img │ │ ├── codeGen_monitoring_ui.png │ │ ├── codeGen_ui_init.jpg │ │ ├── codeGen_ui_response.png │ │ ├── codegen_architecture.png │ │ ├── codegen_auto_complete.jpg │ │ ├── codegen_copilot.png │ │ ├── codegen_customize.png │ │ ├── codegen_dialog.png │ │ ├── codegen_endpoint.png │ │ ├── codegen_gradio_ui_dataprep.png │ │ ├── codegen_gradio_ui_main.png │ │ ├── codegen_gradio_ui_query.png │ │ ├── codegen_gradio_ui_rm.png │ │ ├── codegen_icon.png │ │ ├── codegen_multi_line.png │ │ ├── codegen_qna.png │ │ ├── codegen_react.png │ │ ├── codegen_select_code.png │ │ ├── codegen_settings.png │ │ ├── codegen_single_line.png │ │ ├── codegen_suggestion.png │ │ ├── ui-result-page.png │ │ └── ui-starting-page.png ├── benchmark │ ├── accuracy │ │ ├── README.md │ │ ├── main.py │ │ └── run_acc.sh │ └── performance │ │ ├── README.md │ │ ├── benchmark.sh │ │ └── benchmark.yaml ├── codegen.py ├── docker_compose │ ├── amd │ │ └── gpu │ │ │ └── rocm │ │ │ ├── README.md │ │ │ ├── compose.yaml │ │ │ ├── compose_vllm.yaml │ │ │ ├── set_env.sh │ │ │ └── set_env_vllm.sh │ └── intel │ │ ├── cpu │ │ └── xeon │ │ │ ├── README.md │ │ │ ├── compose.yaml │ │ │ └── compose_remote.yaml │ │ ├── hpu │ │ └── gaudi │ │ │ ├── README.md │ │ │ └── compose.yaml │ │ └── set_env.sh ├── docker_image_build │ └── build.yaml ├── kubernetes │ ├── gmc │ │ ├── README.md │ │ ├── codegen_gaudi.yaml │ │ └── codegen_xeon.yaml │ └── helm │ │ ├── README.md │ │ ├── cpu-tgi-values.yaml │ │ ├── cpu-values.yaml │ │ ├── gaudi-tgi-values.yaml │ │ └── gaudi-values.yaml ├── tests │ ├── README.md │ ├── test_compose_on_gaudi.sh │ ├── test_compose_on_rocm.sh │ ├── test_compose_on_xeon.sh │ ├── test_compose_vllm_on_rocm.sh │ ├── test_gmc_on_gaudi.sh │ └── test_gmc_on_xeon.sh └── ui │ ├── docker │ ├── Dockerfile │ ├── Dockerfile.gradio │ └── Dockerfile.react │ ├── gradio │ ├── README.md │ ├── codegen_ui_gradio.py │ └── requirements.txt │ ├── react │ ├── .env │ ├── .env.production │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── env.sh │ ├── index.html │ ├── nginx.conf │ ├── package.json │ ├── postcss.config.cjs │ ├── src │ │ ├── App.scss │ │ ├── App.tsx │ │ ├── __tests__ │ │ │ └── util.test.ts │ │ ├── assets │ │ │ ├── opea-icon-black.svg │ │ │ └── opea-icon-color.svg │ │ ├── common │ │ │ ├── client.ts │ │ │ └── util.ts │ │ ├── components │ │ │ ├── CodeGen │ │ │ │ ├── CodeGen.tsx │ │ │ │ └── codeGen.module.scss │ │ │ ├── Message │ │ │ │ ├── conversationMessage.module.scss │ │ │ │ └── conversationMessage.tsx │ │ │ ├── Shared │ │ │ │ ├── CodeRender │ │ │ │ │ ├── CodeRender.tsx │ │ │ │ │ └── codeRender.module.scss │ │ │ │ └── Markdown │ │ │ │ │ ├── Markdown.tsx │ │ │ │ │ └── markdown.module.scss │ │ │ └── sidebar │ │ │ │ ├── sidebar.module.scss │ │ │ │ └── sidebar.tsx │ │ ├── config.ts │ │ ├── index.scss │ │ ├── main.tsx │ │ ├── styles │ │ │ ├── components │ │ │ │ ├── _context.scss │ │ │ │ ├── _sidebar.scss │ │ │ │ ├── content.scss │ │ │ │ └── context.module.scss │ │ │ ├── layout │ │ │ │ ├── _basics.scss │ │ │ │ └── _flex.scss │ │ │ └── styles.scss │ │ └── vite-env.d.ts │ ├── tsconfig.json │ ├── tsconfig.node.json │ └── vite.config.ts │ └── svelte │ ├── .editorconfig │ ├── .env │ ├── .eslintignore │ ├── .eslintrc.cjs │ ├── .npmrc │ ├── .prettierignore │ ├── .prettierrc │ ├── README.md │ ├── package.json │ ├── playwright.config.ts │ ├── postcss.config.cjs │ ├── src │ ├── app.d.ts │ ├── app.html │ ├── app.pcss │ ├── app.postcss │ ├── lib │ │ ├── InputAirPlane.svelte │ │ ├── assets │ │ │ ├── PaperAirplane.svelte │ │ │ ├── chat │ │ │ │ └── svelte │ │ │ │ │ └── PaperAirplane.svelte │ │ │ ├── imgLogo.svelte │ │ │ ├── layout │ │ │ │ └── css │ │ │ │ │ └── driver.css │ │ │ ├── loadingAnimation.svelte │ │ │ ├── spinLoading.svelte │ │ │ └── summaryLogo.svelte │ │ ├── doc.svelte │ │ ├── dropFile.svelte │ │ ├── header.svelte │ │ ├── index.ts │ │ ├── modules │ │ │ ├── chat │ │ │ │ └── Output.svelte │ │ │ └── frame │ │ │ │ └── header.svelte │ │ ├── network │ │ │ └── chat │ │ │ │ └── Network.ts │ │ ├── shared │ │ │ ├── Network.ts │ │ │ ├── Store.ts │ │ │ ├── Utils.ts │ │ │ └── components │ │ │ │ ├── loading │ │ │ │ └── Loading.svelte │ │ │ │ └── scrollbar │ │ │ │ └── Scrollbar.svelte │ │ └── summary.svelte │ └── routes │ │ ├── +layout.svelte │ │ ├── +page.svelte │ │ └── +page.ts │ ├── static │ └── favicon.png │ ├── svelte.config.js │ ├── tailwind.config.cjs │ ├── tests │ └── codeGen.spec.ts │ ├── tsconfig.json │ └── vite.config.ts ├── CodeTrans ├── Dockerfile ├── README.md ├── README_miscellaneous.md ├── assets │ └── img │ │ ├── codeTrans_ui_init.png │ │ ├── codeTrans_ui_response.png │ │ ├── codeTrans_ui_select.png │ │ ├── code_trans_architecture.png │ │ ├── example_dashboards.png │ │ ├── tgi_dashboard.png │ │ ├── ui-result-page.png │ │ └── ui-starting-page.png ├── benchmark │ └── performance │ │ ├── README.md │ │ ├── benchmark.sh │ │ └── benchmark.yaml ├── code_translation.py ├── docker_compose │ ├── amd │ │ └── gpu │ │ │ └── rocm │ │ │ ├── README.md │ │ │ ├── compose.yaml │ │ │ ├── compose_vllm.yaml │ │ │ ├── set_env.sh │ │ │ └── set_env_vllm.sh │ └── intel │ │ ├── cpu │ │ └── xeon │ │ │ ├── README.md │ │ │ ├── compose.yaml │ │ │ └── compose_tgi.yaml │ │ ├── hpu │ │ └── gaudi │ │ │ ├── README.md │ │ │ ├── compose.yaml │ │ │ └── compose_tgi.yaml │ │ └── set_env.sh ├── docker_image_build │ └── build.yaml ├── kubernetes │ ├── gmc │ │ ├── README.md │ │ ├── codetrans_gaudi.yaml │ │ └── codetrans_xeon.yaml │ └── helm │ │ ├── README.md │ │ ├── cpu-tgi-values.yaml │ │ ├── cpu-values.yaml │ │ ├── gaudi-tgi-values.yaml │ │ └── gaudi-values.yaml ├── tests │ ├── README.md │ ├── test_compose_on_gaudi.sh │ ├── test_compose_on_rocm.sh │ ├── test_compose_on_xeon.sh │ ├── test_compose_tgi_on_gaudi.sh │ ├── test_compose_tgi_on_xeon.sh │ ├── test_compose_vllm_on_rocm.sh │ ├── test_gmc_on_gaudi.sh │ └── test_gmc_on_xeon.sh └── ui │ ├── docker │ └── Dockerfile │ └── svelte │ ├── .env │ ├── .gitignore │ ├── .npmrc │ ├── README.md │ ├── package.json │ ├── playwright.config.ts │ ├── postcss.config.cjs │ ├── src │ ├── app.d.ts │ ├── app.html │ ├── app.pcss │ ├── lib │ │ ├── assets │ │ │ ├── loadingAnimation.svelte │ │ │ └── translateIcon.svelte │ │ ├── header.svelte │ │ └── shared │ │ │ ├── Network.ts │ │ │ └── constant.ts │ └── routes │ │ ├── +layout.svelte │ │ ├── +page.svelte │ │ └── types.d.ts │ ├── static │ └── favicon.png │ ├── svelte.config.js │ ├── tailwind.config.cjs │ ├── tests │ └── codeTrans.spec.ts │ ├── tsconfig.json │ └── vite.config.ts ├── DBQnA ├── README.md ├── assets │ └── img │ │ ├── dbQnA_ui_db_credentials.png │ │ ├── dbQnA_ui_enter_question.png │ │ ├── dbQnA_ui_failed_db_connection.png │ │ ├── dbQnA_ui_failed_sql_output_generation.png │ │ ├── dbQnA_ui_init.png │ │ ├── dbQnA_ui_succesful_sql_output_generation.png │ │ └── dbQnA_ui_successful_db_connection.png ├── docker_compose │ ├── amd │ │ └── gpu │ │ │ └── rocm │ │ │ ├── README.md │ │ │ ├── chinook.sql │ │ │ ├── compose.yaml │ │ │ └── set_env.sh │ └── intel │ │ └── cpu │ │ └── xeon │ │ ├── README.md │ │ ├── chinook.sql │ │ ├── compose.yaml │ │ └── set_env.sh ├── docker_image_build │ └── build.yaml ├── tests │ ├── README.md │ ├── test_compose_on_rocm.sh │ └── test_compose_on_xeon.sh └── ui │ ├── docker │ └── Dockerfile.react │ └── react │ ├── .env │ ├── .gitignore │ ├── README.md │ ├── index.html │ ├── nginx.conf │ ├── package.json │ ├── postcss.config.cjs │ ├── src │ ├── App.scss │ ├── App.test.tsx │ ├── App.tsx │ ├── assets │ │ ├── opea-icon-black.svg │ │ └── opea-icon-color.svg │ ├── components │ │ ├── DbConnect │ │ │ ├── DBConnect.tsx │ │ │ └── dbconnect.module.scss │ │ └── sidebar │ │ │ ├── sidebar.module.scss │ │ │ └── sidebar.tsx │ ├── config.ts │ ├── index.scss │ ├── index.tsx │ ├── logo.svg │ ├── main.tsx │ ├── styles │ │ ├── layout │ │ │ ├── _basics.scss │ │ │ └── _flex.scss │ │ └── styles.scss │ └── vite-env.d.ts │ ├── tsconfig.json │ ├── tsconfig.node.json │ └── vite.config.ts ├── DocIndexRetriever ├── Dockerfile ├── README.md ├── docker_compose │ └── intel │ │ ├── cpu │ │ └── xeon │ │ │ ├── README.md │ │ │ ├── compose.yaml │ │ │ ├── compose_milvus.yaml │ │ │ ├── compose_without_rerank.yaml │ │ │ ├── config │ │ │ └── milvus.yaml │ │ │ └── set_env.sh │ │ └── hpu │ │ └── gaudi │ │ ├── README.md │ │ ├── compose.yaml │ │ ├── compose_milvus.yaml │ │ ├── config │ │ └── milvus.yaml │ │ └── set_env.sh ├── docker_image_build │ └── build.yaml ├── retrieval_tool.py └── tests │ ├── README.md │ ├── test.py │ ├── test_compose_milvus_on_gaudi.sh │ ├── test_compose_milvus_on_xeon.sh │ ├── test_compose_on_gaudi.sh │ ├── test_compose_on_xeon.sh │ └── test_compose_without_rerank_on_xeon.sh ├── DocSum ├── Dockerfile ├── README.md ├── README_miscellaneous.md ├── assets │ └── img │ │ ├── docSum_ui_exchange.png │ │ ├── docSum_ui_gradio_text.png │ │ ├── docSum_ui_response.png │ │ ├── docSum_ui_text.png │ │ ├── docSum_ui_upload.png │ │ ├── docsum-ui-react-error.png │ │ ├── docsum-ui-react-file.png │ │ ├── docsum-ui-react.png │ │ ├── docsum_architecture.png │ │ ├── docsum_workflow.png │ │ ├── ui-result-page.png │ │ └── ui-starting-page.png ├── benchmark_docsum.yaml ├── docker_compose │ ├── amd │ │ └── gpu │ │ │ └── rocm │ │ │ ├── README.md │ │ │ ├── compose.yaml │ │ │ ├── compose_vllm.yaml │ │ │ ├── set_env.sh │ │ │ └── set_env_vllm.sh │ └── intel │ │ ├── cpu │ │ └── xeon │ │ │ ├── README.md │ │ │ ├── compose.yaml │ │ │ └── compose_tgi.yaml │ │ ├── hpu │ │ └── gaudi │ │ │ ├── README.md │ │ │ ├── compose.yaml │ │ │ └── compose_tgi.yaml │ │ └── set_env.sh ├── docker_image_build │ └── build.yaml ├── docsum.py ├── kubernetes │ ├── gmc │ │ ├── README.md │ │ ├── docsum_gaudi.yaml │ │ └── docsum_xeon.yaml │ └── helm │ │ ├── README.md │ │ ├── cpu-tgi-values.yaml │ │ ├── cpu-values.yaml │ │ ├── gaudi-tgi-values.yaml │ │ ├── gaudi-values.yaml │ │ ├── rocm-tgi-values.yaml │ │ └── rocm-values.yaml ├── tests │ ├── README.md │ ├── data │ │ ├── long.txt │ │ ├── short.txt │ │ ├── test.mp4 │ │ └── test.wav │ ├── test_compose_on_gaudi.sh │ ├── test_compose_on_rocm.sh │ ├── test_compose_on_xeon.sh │ ├── test_compose_tgi_on_gaudi.sh │ ├── test_compose_tgi_on_xeon.sh │ ├── test_compose_vllm_on_rocm.sh │ ├── test_gmc_on_gaudi.sh │ └── test_gmc_on_xeon.sh └── ui │ ├── docker │ ├── Dockerfile │ ├── Dockerfile.gradio │ └── Dockerfile.react │ ├── gradio │ ├── README.md │ ├── docsum_ui_gradio.py │ └── requirements.txt │ ├── react │ ├── .env │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── index.html │ ├── nginx.conf │ ├── package.json │ ├── postcss.config.cjs │ ├── src │ │ ├── App.scss │ │ ├── App.tsx │ │ ├── __tests__ │ │ │ └── util.test.ts │ │ ├── assets │ │ │ ├── opea-icon-black.svg │ │ │ └── opea-icon-color.svg │ │ ├── common │ │ │ ├── client.ts │ │ │ └── util.ts │ │ ├── components │ │ │ ├── DocSum │ │ │ │ ├── DocSum.tsx │ │ │ │ ├── FileUpload.tsx │ │ │ │ └── docSum.module.scss │ │ │ ├── Shared │ │ │ │ ├── CodeRender │ │ │ │ │ ├── CodeRender.tsx │ │ │ │ │ └── codeRender.module.scss │ │ │ │ └── Markdown │ │ │ │ │ ├── Markdown.tsx │ │ │ │ │ └── markdown.module.scss │ │ │ └── sidebar │ │ │ │ ├── sidebar.module.scss │ │ │ │ └── sidebar.tsx │ │ ├── config.ts │ │ ├── index.scss │ │ ├── main.tsx │ │ ├── styles │ │ │ ├── components │ │ │ │ ├── _sidebar.scss │ │ │ │ ├── content.scss │ │ │ │ └── context.module.scss │ │ │ ├── layout │ │ │ │ ├── _basics.scss │ │ │ │ └── _flex.scss │ │ │ └── styles.scss │ │ └── vite-env.d.ts │ ├── tsconfig.json │ ├── tsconfig.node.json │ └── vite.config.ts │ └── svelte │ ├── .env │ ├── .gitignore │ ├── .npmrc │ ├── README.md │ ├── package.json │ ├── playwright.config.ts │ ├── postcss.config.cjs │ ├── src │ ├── app.d.ts │ ├── app.html │ ├── app.pcss │ ├── lib │ │ ├── assets │ │ │ ├── imgLogo.svelte │ │ │ ├── intelLogo.svelte │ │ │ ├── loadingAnimation.svelte │ │ │ ├── spinLoading.svelte │ │ │ └── summaryLogo.svelte │ │ ├── doc.svelte │ │ ├── dropFile.svelte │ │ ├── header.svelte │ │ ├── index.ts │ │ ├── shared │ │ │ ├── Network.ts │ │ │ ├── Store.ts │ │ │ └── Utils.ts │ │ └── summary.svelte │ └── routes │ │ ├── +layout.svelte │ │ └── +page.svelte │ ├── static │ └── favicon.png │ ├── svelte.config.js │ ├── tailwind.config.cjs │ ├── tests │ └── docSum.spec.ts │ ├── tsconfig.json │ └── vite.config.ts ├── EdgeCraftRAG ├── Dockerfile ├── Dockerfile.server ├── README.md ├── assets │ └── img │ │ ├── chat_with_rag.png │ │ ├── create_pipeline.png │ │ └── upload_data.png ├── chatqna.py ├── docker_compose │ └── intel │ │ └── gpu │ │ └── arc │ │ ├── compose.yaml │ │ ├── compose_gradio.yaml │ │ ├── compose_vllm.yaml │ │ ├── compose_vllm_multi-arc.yaml │ │ └── set_env.sh ├── docker_image_build │ └── build.yaml ├── edgecraftrag │ ├── __init__.py │ ├── api │ │ ├── __init__.py │ │ └── v1 │ │ │ ├── __init__.py │ │ │ ├── chatqna.py │ │ │ ├── data.py │ │ │ ├── model.py │ │ │ ├── pipeline.py │ │ │ └── system.py │ ├── api_schema.py │ ├── base.py │ ├── components │ │ ├── __init__.py │ │ ├── benchmark.py │ │ ├── data.py │ │ ├── generator.py │ │ ├── indexer.py │ │ ├── model.py │ │ ├── node_parser.py │ │ ├── pipeline.py │ │ ├── postprocessor.py │ │ └── retriever.py │ ├── context.py │ ├── controllers │ │ ├── __init__.py │ │ ├── compmgr.py │ │ ├── filemgr.py │ │ ├── modelmgr.py │ │ ├── nodemgr.py │ │ └── pipelinemgr.py │ ├── prompt_template │ │ └── default_prompt.txt │ ├── requirements.txt │ ├── server.py │ └── utils.py ├── tests │ ├── README.md │ ├── common.sh │ ├── configs │ │ ├── test_data.json │ │ ├── test_pipeline_local_llm.json │ │ └── test_pipeline_vllm.json │ ├── test_compose_on_arc.sh │ ├── test_compose_vllm_on_arc.sh │ └── test_pipeline_local_llm.json └── ui │ ├── docker │ ├── Dockerfile.gradio │ └── Dockerfile.ui │ ├── gradio │ ├── __init__.py │ ├── assets │ │ ├── ai-logo-inline-ondark-3000.png │ │ └── ai-logo-inline-onlight-3000.png │ ├── config.py │ ├── default.yaml │ ├── ecrag_client.py │ ├── ecragui.py │ ├── platform_config.py │ └── requirements.txt │ └── vue │ ├── .env.development │ ├── .env.production │ ├── .gitignore │ ├── README.md │ ├── auto-imports.d.ts │ ├── components.d.ts │ ├── index.html │ ├── nginx.conf │ ├── package.json │ ├── public │ ├── favicon.ico │ └── favicon1.ico │ ├── src │ ├── App.vue │ ├── api │ │ ├── chatbot │ │ │ └── index.ts │ │ ├── pipeline │ │ │ └── index.ts │ │ └── request.ts │ ├── assets │ │ ├── iconFont │ │ │ ├── iconfont.css │ │ │ ├── iconfont.js │ │ │ ├── iconfont.json │ │ │ ├── iconfont.ttf │ │ │ ├── iconfont.woff │ │ │ └── iconfont.woff2 │ │ ├── images │ │ │ ├── 404-bg.png │ │ │ └── noData.png │ │ └── svgs │ │ │ ├── 404-icon.svg │ │ │ ├── dark-icon.svg │ │ │ ├── header-log.svg │ │ │ ├── light-icon.svg │ │ │ ├── lightBulb.svg │ │ │ └── uploaded.svg │ ├── auto-imports.d.ts │ ├── components.d.ts │ ├── components │ │ ├── FormTooltip.vue │ │ └── SvgIcon.vue │ ├── enums │ │ └── antEnum.ts │ ├── i18n │ │ ├── en.ts │ │ ├── index.ts │ │ └── zh.ts │ ├── layout │ │ ├── Header.vue │ │ └── Main.vue │ ├── main.ts │ ├── router │ │ ├── index.ts │ │ └── routes.ts │ ├── store │ │ ├── chatbot.ts │ │ ├── index.ts │ │ ├── pipeline.ts │ │ ├── theme.ts │ │ └── user.ts │ ├── theme │ │ ├── ant.less │ │ ├── common.less │ │ ├── index.less │ │ ├── layout.less │ │ ├── loading.less │ │ ├── markdown.less │ │ └── variables.less │ ├── types │ │ ├── axios.d.ts │ │ └── global.d.ts │ ├── utils │ │ ├── antTheme.ts │ │ ├── common.ts │ │ ├── loading.ts │ │ ├── notification.ts │ │ ├── other.ts │ │ ├── serviceManager.ts │ │ └── storage.ts │ ├── views │ │ ├── chatbot │ │ │ ├── components │ │ │ │ ├── Chatbot.vue │ │ │ │ ├── ConfigDrawer.vue │ │ │ │ ├── Header.vue │ │ │ │ ├── MessageItem.vue │ │ │ │ ├── SseService.ts │ │ │ │ ├── UploadFile.vue │ │ │ │ └── index.ts │ │ │ ├── index.vue │ │ │ └── type.ts │ │ ├── error │ │ │ └── 404.vue │ │ └── pipeline │ │ │ ├── components │ │ │ ├── Configuration.vue │ │ │ ├── DetailDrawer.vue │ │ │ ├── ImportDialog.vue │ │ │ ├── QuickStart.vue │ │ │ ├── System.vue │ │ │ ├── SystemChart.vue │ │ │ ├── Table.vue │ │ │ ├── UpdateDialog │ │ │ │ ├── Activated.vue │ │ │ │ ├── Basic.vue │ │ │ │ ├── CreateDialog.vue │ │ │ │ ├── EditDialog.vue │ │ │ │ ├── Generator.vue │ │ │ │ ├── Indexer.vue │ │ │ │ ├── NodeParser.vue │ │ │ │ ├── PostProcessor.vue │ │ │ │ ├── Retriever.vue │ │ │ │ └── index.ts │ │ │ └── index.ts │ │ │ ├── enum.ts │ │ │ ├── index.vue │ │ │ └── type.ts │ └── vite-env.d.ts │ ├── tsconfig.app.json │ ├── tsconfig.json │ ├── tsconfig.node.json │ └── vite.config.ts ├── FinanceAgent ├── README.md ├── assets │ ├── fin_agent_dataprep.png │ ├── finance_agent_arch.png │ ├── finqa_tool.png │ ├── opea-agent-setting.png │ ├── opea-agent-test.png │ ├── ui_connections_settings.png │ └── upload_doc_ui.png ├── docker_compose │ └── intel │ │ ├── hpu │ │ └── gaudi │ │ │ ├── README.md │ │ │ └── compose.yaml │ │ └── set_env.sh ├── docker_image_build │ └── build.yaml ├── prompts │ ├── finqa_prompt.py │ ├── research_prompt.py │ └── supervisor_prompt.py ├── tests │ ├── test.py │ ├── test_compose_on_gaudi.sh │ └── test_redis_finance.py └── tools │ ├── finqa_agent_tools.yaml │ ├── finqa_tools.py │ ├── redis_kv.py │ ├── research_agent_tools.yaml │ ├── research_tools.py │ ├── sum_agent_tools.py │ ├── supervisor_agent_tools.yaml │ ├── supervisor_tools.py │ └── utils.py ├── GraphRAG ├── Dockerfile ├── README.md ├── assets │ ├── 8microservices.png │ └── img │ │ ├── chat_ui_init.png │ │ ├── chat_ui_response.png │ │ ├── chat_ui_upload.png │ │ ├── chatqna_architecture.png │ │ ├── chatqna_dashboards.png │ │ ├── chatqna_flow_chart.png │ │ ├── conversation_ui_init.png │ │ ├── conversation_ui_response.png │ │ ├── conversation_ui_upload.png │ │ └── tgi_dashboard.png ├── docker_compose │ └── intel │ │ └── hpu │ │ └── gaudi │ │ ├── compose.yaml │ │ └── set_env.sh ├── docker_image_build │ └── build.yaml ├── graphrag.py ├── tests │ ├── README.md │ └── test_compose_on_gaudi.sh └── ui │ ├── docker │ ├── Dockerfile │ └── Dockerfile.react │ ├── react │ ├── .env │ ├── .env.production │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── env.sh │ ├── index.html │ ├── nginx.conf │ ├── package.json │ ├── postcss.config.cjs │ ├── public │ │ └── vite.svg │ ├── src │ │ ├── App.scss │ │ ├── App.tsx │ │ ├── __tests__ │ │ │ └── util.test.ts │ │ ├── assets │ │ │ ├── opea-icon-black.svg │ │ │ ├── opea-icon-color.svg │ │ │ └── react.svg │ │ ├── common │ │ │ ├── client.ts │ │ │ └── util.ts │ │ ├── components │ │ │ ├── Conversation │ │ │ │ ├── Conversation.tsx │ │ │ │ ├── ConversationSideBar.tsx │ │ │ │ ├── DataSource.tsx │ │ │ │ └── conversation.module.scss │ │ │ ├── Message │ │ │ │ ├── conversationMessage.module.scss │ │ │ │ └── conversationMessage.tsx │ │ │ ├── UserInfoModal │ │ │ │ └── UserInfoModal.tsx │ │ │ └── sidebar │ │ │ │ ├── sidebar.module.scss │ │ │ │ └── sidebar.tsx │ │ ├── config.ts │ │ ├── index.scss │ │ ├── main.tsx │ │ ├── redux │ │ │ ├── Conversation │ │ │ │ ├── Conversation.ts │ │ │ │ └── ConversationSlice.ts │ │ │ ├── User │ │ │ │ ├── user.d.ts │ │ │ │ └── userSlice.ts │ │ │ ├── store.ts │ │ │ └── thunkUtil.ts │ │ ├── styles │ │ │ ├── components │ │ │ │ ├── _context.scss │ │ │ │ ├── _sidebar.scss │ │ │ │ ├── content.scss │ │ │ │ └── context.module.scss │ │ │ ├── layout │ │ │ │ ├── _basics.scss │ │ │ │ └── _flex.scss │ │ │ └── styles.scss │ │ └── vite-env.d.ts │ ├── tsconfig.json │ ├── tsconfig.node.json │ └── vite.config.ts │ └── svelte │ ├── .editorconfig │ ├── .env │ ├── .eslintignore │ ├── .eslintrc.cjs │ ├── .prettierignore │ ├── .prettierrc │ ├── README.md │ ├── package.json │ ├── playwright.config.ts │ ├── postcss.config.cjs │ ├── src │ ├── app.d.ts │ ├── app.html │ ├── app.postcss │ ├── lib │ │ ├── assets │ │ │ ├── DocManagement │ │ │ │ ├── LinkfolderIcon.svelte │ │ │ │ ├── fileIcon.svelte │ │ │ │ └── folderIcon.svelte │ │ │ ├── avatar │ │ │ │ └── svelte │ │ │ │ │ └── Delete.svelte │ │ │ ├── chat │ │ │ │ └── svelte │ │ │ │ │ ├── Assistant.svelte │ │ │ │ │ ├── PaperAirplane.svelte │ │ │ │ │ └── PersonOutlined.svelte │ │ │ ├── layout │ │ │ │ └── css │ │ │ │ │ └── driver.css │ │ │ ├── upload │ │ │ │ ├── deleteIcon.svelte │ │ │ │ ├── loading-button.svelte │ │ │ │ ├── next.svelte │ │ │ │ ├── no-file.svelte │ │ │ │ └── previous.svelte │ │ │ └── voice │ │ │ │ └── svg │ │ │ │ ├── paste.svg │ │ │ │ └── uploadFile.svg │ │ ├── modules │ │ │ ├── chat │ │ │ │ ├── ChatMessage.svelte │ │ │ │ ├── MessageAvatar.svelte │ │ │ │ └── MessageTimer.svelte │ │ │ └── frame │ │ │ │ └── Layout.svelte │ │ ├── network │ │ │ ├── chat │ │ │ │ └── Network.ts │ │ │ └── upload │ │ │ │ └── Network.ts │ │ └── shared │ │ │ ├── Utils.ts │ │ │ ├── components │ │ │ ├── chat │ │ │ │ └── gallery.svelte │ │ │ ├── doc_management │ │ │ │ ├── docCard.svelte │ │ │ │ └── treeView │ │ │ │ │ ├── svelte-tree.svelte │ │ │ │ │ ├── tree-branch.svelte │ │ │ │ │ └── tree-node.svelte │ │ │ ├── loading │ │ │ │ └── Loading.svelte │ │ │ ├── scrollbar │ │ │ │ └── Scrollbar.svelte │ │ │ └── upload │ │ │ │ ├── PasteKnowledge.svelte │ │ │ │ ├── upload-knowledge.svelte │ │ │ │ └── uploadFile.svelte │ │ │ ├── constant │ │ │ └── Interface.ts │ │ │ └── stores │ │ │ └── common │ │ │ └── Store.ts │ └── routes │ │ ├── +layout.svelte │ │ ├── +page.svelte │ │ └── +page.ts │ ├── static │ └── favicon.png │ ├── svelte.config.js │ ├── tailwind.config.cjs │ ├── tests │ ├── chatQnA.spec.ts │ └── test_file.txt │ ├── tsconfig.json │ └── vite.config.ts ├── HybridRAG ├── Dockerfile ├── README.md ├── README_NOTICE.md ├── assets │ └── img │ │ ├── chat_ui_init.png │ │ ├── chat_ui_response.png │ │ ├── chat_ui_upload.png │ │ └── hybridrag_retriever_architecture.png ├── docker_compose │ └── intel │ │ └── hpu │ │ └── gaudi │ │ ├── README.md │ │ ├── compose.yaml │ │ └── set_env.sh ├── docker_image_build │ └── build.yaml ├── hybridrag.py ├── tests │ ├── data │ │ ├── Acne_Vulgaris.txt │ │ └── Diabetes.txt │ └── test_compose_on_gaudi.sh └── ui │ ├── docker │ └── Dockerfile │ └── svelte │ ├── .editorconfig │ ├── .env │ ├── .eslintignore │ ├── .eslintrc.cjs │ ├── .prettierignore │ ├── .prettierrc │ ├── README.md │ ├── package.json │ ├── playwright.config.ts │ ├── postcss.config.cjs │ ├── src │ ├── app.d.ts │ ├── app.html │ ├── app.postcss │ ├── lib │ │ ├── assets │ │ │ ├── DocManagement │ │ │ │ ├── LinkfolderIcon.svelte │ │ │ │ ├── fileIcon.svelte │ │ │ │ └── folderIcon.svelte │ │ │ ├── avatar │ │ │ │ └── svelte │ │ │ │ │ └── Delete.svelte │ │ │ ├── chat │ │ │ │ └── svelte │ │ │ │ │ ├── Assistant.svelte │ │ │ │ │ ├── PaperAirplane.svelte │ │ │ │ │ └── PersonOutlined.svelte │ │ │ ├── layout │ │ │ │ └── css │ │ │ │ │ └── driver.css │ │ │ ├── upload │ │ │ │ ├── deleteIcon.svelte │ │ │ │ ├── loading-button.svelte │ │ │ │ ├── next.svelte │ │ │ │ ├── no-file.svelte │ │ │ │ └── previous.svelte │ │ │ └── voice │ │ │ │ └── svg │ │ │ │ ├── paste.svg │ │ │ │ └── uploadFile.svg │ │ ├── modules │ │ │ ├── chat │ │ │ │ ├── ChatMessage.svelte │ │ │ │ ├── MessageAvatar.svelte │ │ │ │ └── MessageTimer.svelte │ │ │ └── frame │ │ │ │ └── Layout.svelte │ │ ├── network │ │ │ ├── chat │ │ │ │ └── Network.ts │ │ │ └── upload │ │ │ │ └── Network.ts │ │ └── shared │ │ │ ├── Utils.ts │ │ │ ├── components │ │ │ ├── chat │ │ │ │ └── gallery.svelte │ │ │ ├── doc_management │ │ │ │ ├── docCard.svelte │ │ │ │ └── treeView │ │ │ │ │ ├── svelte-tree.svelte │ │ │ │ │ ├── tree-branch.svelte │ │ │ │ │ └── tree-node.svelte │ │ │ ├── loading │ │ │ │ ├── Loading.svelte │ │ │ │ └── Spinner.svelte │ │ │ ├── scrollbar │ │ │ │ └── Scrollbar.svelte │ │ │ └── upload │ │ │ │ ├── PasteKnowledge.svelte │ │ │ │ ├── upload-knowledge.svelte │ │ │ │ └── uploadFile.svelte │ │ │ ├── constant │ │ │ └── Interface.ts │ │ │ └── stores │ │ │ └── common │ │ │ └── Store.ts │ └── routes │ │ ├── +layout.svelte │ │ ├── +page.svelte │ │ └── +page.ts │ ├── static │ └── favicon.png │ ├── svelte.config.js │ ├── tailwind.config.cjs │ ├── tests │ ├── chatQnA.spec.ts │ └── test_file.txt │ ├── tsconfig.json │ └── vite.config.ts ├── InstructionTuning ├── README.md ├── docker_compose │ └── intel │ │ ├── cpu │ │ └── xeon │ │ │ └── README.md │ │ └── hpu │ │ └── gaudi │ │ └── README.md ├── docker_image_build │ └── build.yaml └── tests │ ├── README.md │ └── test_compose_on_xeon.sh ├── LEGAL_INFORMATION.md ├── LICENSE ├── MultimodalQnA ├── Dockerfile ├── README.md ├── assets │ └── img │ │ ├── MultimodalQnA.png │ │ ├── audio-ingestion.png │ │ ├── audio-query.png │ │ ├── image-ingestion.png │ │ ├── image-query-text.png │ │ ├── image-query-tts.png │ │ ├── mmqna-ui.png │ │ ├── pdf-ingestion.png │ │ ├── pdf-query.png │ │ ├── vector-store.png │ │ ├── video-ingestion.png │ │ └── video-query.png ├── docker_compose │ ├── amd │ │ └── gpu │ │ │ └── rocm │ │ │ ├── README.md │ │ │ ├── compose.yaml │ │ │ ├── compose_vllm.yaml │ │ │ ├── set_env.sh │ │ │ └── set_env_vllm.sh │ └── intel │ │ ├── cpu │ │ └── xeon │ │ │ ├── README.md │ │ │ ├── compose.yaml │ │ │ ├── compose_milvus.yaml │ │ │ └── config │ │ │ └── milvus.yaml │ │ ├── hpu │ │ └── gaudi │ │ │ ├── README.md │ │ │ ├── compose.yaml │ │ │ ├── compose_milvus.yaml │ │ │ └── config │ │ │ └── milvus.yaml │ │ └── set_env.sh ├── docker_image_build │ └── build.yaml ├── multimodalqna.py ├── tests │ ├── README.md │ ├── test_compose_milvus_on_xeon.sh │ ├── test_compose_on_gaudi.sh │ ├── test_compose_on_rocm.sh │ ├── test_compose_on_xeon.sh │ └── test_compose_vllm_on_rocm.sh └── ui │ ├── docker │ └── Dockerfile │ └── gradio │ ├── conversation.py │ ├── multimodalqna_ui_gradio.py │ ├── requirements.txt │ └── utils.py ├── ProductivitySuite ├── README.md ├── assets │ └── img │ │ ├── Login_page.png │ │ ├── chat_qna_init.png │ │ ├── chatqna_with_conversation.png │ │ ├── codegen.png │ │ ├── create_client.png │ │ ├── create_productivitysuite_realm.png │ │ ├── create_realm.png │ │ ├── create_roles.png │ │ ├── create_users.png │ │ ├── data_source.png │ │ ├── doc_summary.png │ │ ├── doc_summary_file.png │ │ ├── doc_summary_paste.png │ │ ├── faq_generator.png │ │ ├── keycloak_login.png │ │ ├── productivitysuite_client_settings.png │ │ ├── set_user_password.png │ │ └── user_role_mapping.png ├── docker_compose │ └── intel │ │ └── cpu │ │ └── xeon │ │ ├── README.md │ │ ├── compose.yaml │ │ ├── keycloak_setup_guide.md │ │ └── set_env.sh ├── docker_image_build │ └── build.yaml ├── tests │ ├── README.md │ └── test_compose_on_xeon.sh └── ui │ ├── docker │ └── Dockerfile.react │ └── react │ ├── .env.production │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── env.sh │ ├── index.html │ ├── nginx.conf │ ├── package.json │ ├── public │ ├── favicon.ico │ ├── logo192.png │ ├── logo512.png │ ├── manifest.json │ ├── model_configs.json │ └── robots.txt │ ├── src │ ├── App.scss │ ├── App.tsx │ ├── __tests__ │ │ └── util.test.ts │ ├── assets │ │ └── icons │ │ │ ├── moon.svg │ │ │ └── sun.svg │ ├── common │ │ └── util.ts │ ├── components │ │ ├── Chat_Assistant │ │ │ ├── ChatAssistant.module.scss │ │ │ └── ChatAssistant.tsx │ │ ├── Chat_Markdown │ │ │ ├── ChatMarkdown.tsx │ │ │ ├── CodeRender │ │ │ │ ├── CodeRender.tsx │ │ │ │ └── codeRender.module.scss │ │ │ └── markdown.module.scss │ │ ├── Chat_SettingsModal │ │ │ ├── ChatSettingsModal.module.scss │ │ │ └── ChatSettingsModal.tsx │ │ ├── Chat_Sources │ │ │ ├── ChatSources.module.scss │ │ │ └── ChatSources.tsx │ │ ├── Chat_User │ │ │ ├── ChatUser.module.scss │ │ │ └── ChatUser.tsx │ │ ├── Data_Web │ │ │ └── DataWebInput.tsx │ │ ├── DropDown │ │ │ ├── DropDown.module.scss │ │ │ └── DropDown.tsx │ │ ├── File_Display │ │ │ ├── FileDisplay.module.scss │ │ │ └── FileDisplay.tsx │ │ ├── File_Input │ │ │ ├── FileInput.module.scss │ │ │ └── FileInput.tsx │ │ ├── Header │ │ │ ├── Header.module.scss │ │ │ └── Header.tsx │ │ ├── Header_DownloadChat │ │ │ └── DownloadChat.tsx │ │ ├── Header_ThemeToggle │ │ │ ├── ThemeToggle.module.scss │ │ │ └── ThemeToggle.tsx │ │ ├── Notification │ │ │ └── Notification.tsx │ │ ├── PrimaryInput │ │ │ ├── PrimaryInput.module.scss │ │ │ └── PrimaryInput.tsx │ │ ├── PrimaryInput_AudioInput │ │ │ └── AudioInput.tsx │ │ ├── PrimparyInput_PromptSelector │ │ │ ├── PromptSelector.module.scss │ │ │ └── PromptSelector.tsx │ │ ├── ProgressIcon │ │ │ └── ProgressIcon.tsx │ │ ├── PromptSettings │ │ │ ├── PromptSettings.module.scss │ │ │ └── PromptSettings.tsx │ │ ├── PromptSettings_Slider │ │ │ ├── Slider.module.scss │ │ │ └── Slider.tsx │ │ ├── PromptSettings_Tokens │ │ │ ├── TokensInput.module.scss │ │ │ └── TokensInput.tsx │ │ ├── SearchInput │ │ │ ├── SearchInput.module.scss │ │ │ └── SearchInput.tsx │ │ ├── SideBar │ │ │ ├── SideBar.module.scss │ │ │ └── SideBar.tsx │ │ ├── SideBar_UploadChat │ │ │ └── UploadChat.tsx │ │ └── Summary_WebInput │ │ │ ├── WebInput.module.scss │ │ │ └── WebInput.tsx │ ├── config.ts │ ├── contexts │ │ └── ThemeContext.tsx │ ├── icons │ │ ├── Atom.tsx │ │ ├── ChatBubble.tsx │ │ ├── Database.tsx │ │ ├── Recent.tsx │ │ └── Waiting.tsx │ ├── index.scss │ ├── index.tsx │ ├── keycloak.ts │ ├── layouts │ │ ├── Main │ │ │ ├── MainLayout.module.scss │ │ │ └── MainLayout.tsx │ │ ├── Minimal │ │ │ ├── MinimalLayout.module.scss │ │ │ └── MinimalLayout.tsx │ │ └── ProtectedRoute │ │ │ └── ProtectedRoute.tsx │ ├── logo.svg │ ├── pages │ │ ├── Chat │ │ │ ├── ChatView.module.scss │ │ │ └── ChatView.tsx │ │ ├── DataSource │ │ │ ├── DataSourceManagement.module.scss │ │ │ └── DataSourceManagement.tsx │ │ ├── History │ │ │ ├── HistoryView.module.scss │ │ │ └── HistoryView.tsx │ │ └── Home │ │ │ ├── Home.module.scss │ │ │ └── Home.tsx │ ├── redux │ │ ├── Conversation │ │ │ ├── Conversation.ts │ │ │ └── ConversationSlice.ts │ │ ├── Prompt │ │ │ └── PromptSlice.ts │ │ ├── User │ │ │ ├── user.d.ts │ │ │ └── userSlice.ts │ │ ├── store.ts │ │ └── thunkUtil.ts │ ├── shared │ │ ├── ActionButtons.tsx │ │ └── ModalBox │ │ │ ├── Modal.module.scss │ │ │ └── ModalBox.tsx │ ├── theme │ │ └── theme.tsx │ ├── types │ │ ├── common.ts │ │ ├── conversation.ts │ │ ├── global.d.ts │ │ ├── speech.d.ts │ │ ├── styles.d.ts │ │ └── theme.d.ts │ ├── utils │ │ └── utils.js │ └── vite-env.d.ts │ ├── tsconfig.json │ ├── tsconfig.node.json │ └── vite.config.js ├── README-deploy-benchmark.md ├── README.md ├── RerankFinetuning ├── README.md ├── docker_compose │ └── intel │ │ ├── cpu │ │ └── xeon │ │ │ └── README.md │ │ └── hpu │ │ └── gaudi │ │ └── README.md ├── docker_image_build │ └── build.yaml └── tests │ ├── test_compose_on_gaudi.sh │ └── test_compose_on_xeon.sh ├── SearchQnA ├── Dockerfile ├── README.md ├── README_miscellaneous.md ├── assets │ └── img │ │ ├── search_ui_init.png │ │ ├── searchqna-ui-response-example.png │ │ ├── searchqna-ui-starting-page.png │ │ └── searchqna.png ├── docker_compose │ ├── amd │ │ └── gpu │ │ │ └── rocm │ │ │ ├── README.md │ │ │ ├── compose.yaml │ │ │ ├── compose_vllm.yaml │ │ │ ├── set_env.sh │ │ │ └── set_env_vllm.sh │ └── intel │ │ ├── cpu │ │ └── xeon │ │ │ ├── README.md │ │ │ └── compose.yaml │ │ ├── hpu │ │ └── gaudi │ │ │ ├── README.md │ │ │ └── compose.yaml │ │ └── set_env.sh ├── docker_image_build │ └── build.yaml ├── kubernetes │ ├── gmc │ │ ├── README.md │ │ ├── searchQnA_gaudi.yaml │ │ └── searchQnA_xeon.yaml │ └── helm │ │ ├── README.md │ │ ├── cpu-values.yaml │ │ └── gaudi-values.yaml ├── searchqna.py ├── tests │ ├── README.md │ ├── test_compose_on_gaudi.sh │ ├── test_compose_on_rocm.sh │ ├── test_compose_on_xeon.sh │ ├── test_compose_vllm_on_rocm.sh │ ├── test_gmc_on_gaudi.sh │ └── test_gmc_on_xeon.sh └── ui │ ├── docker │ └── Dockerfile │ └── svelte │ ├── .editorconfig │ ├── .env │ ├── .eslintignore │ ├── .eslintrc.cjs │ ├── .prettierignore │ ├── .prettierrc │ ├── README.md │ ├── package.json │ ├── playwright.config.ts │ ├── postcss.config.cjs │ ├── src │ ├── app.d.ts │ ├── app.html │ ├── app.postcss │ ├── lib │ │ ├── assets │ │ │ ├── avatar │ │ │ │ └── svelte │ │ │ │ │ └── Delete.svelte │ │ │ ├── chat │ │ │ │ └── svelte │ │ │ │ │ ├── Assistant.svelte │ │ │ │ │ ├── PaperAirplane.svelte │ │ │ │ │ └── PersonOutlined.svelte │ │ │ ├── header │ │ │ │ └── intelLogo.svelte │ │ │ ├── layout │ │ │ │ └── css │ │ │ │ │ └── driver.css │ │ │ ├── upload │ │ │ │ ├── next.svelte │ │ │ │ └── previous.svelte │ │ │ └── voice │ │ │ │ └── svg │ │ │ │ ├── paste.svg │ │ │ │ └── uploadFile.svg │ │ ├── modules │ │ │ ├── chat │ │ │ │ ├── ChatMessage.svelte │ │ │ │ ├── MessageAvatar.svelte │ │ │ │ └── MessageTimer.svelte │ │ │ └── frame │ │ │ │ └── Layout.svelte │ │ ├── network │ │ │ ├── chat │ │ │ │ └── Network.ts │ │ │ └── upload │ │ │ │ └── Network.ts │ │ └── shared │ │ │ ├── Utils.ts │ │ │ ├── components │ │ │ ├── header │ │ │ │ └── header.svelte │ │ │ ├── loading │ │ │ │ └── Loading.svelte │ │ │ └── scrollbar │ │ │ │ └── Scrollbar.svelte │ │ │ ├── constant │ │ │ └── Interface.ts │ │ │ └── stores │ │ │ └── common │ │ │ └── Store.ts │ └── routes │ │ ├── +layout.svelte │ │ ├── +page.svelte │ │ └── +page.ts │ ├── static │ └── favicon.png │ ├── svelte.config.js │ ├── tailwind.config.cjs │ ├── tests │ └── searchQnA.spec.ts │ ├── tsconfig.json │ └── vite.config.ts ├── Text2Image ├── README.md ├── assets │ └── img │ │ ├── text2img_init.png │ │ └── text2img_response.png ├── docker_compose │ └── intel │ │ ├── cpu │ │ └── xeon │ │ │ ├── README.md │ │ │ └── compose.yaml │ │ └── hpu │ │ └── gaudi │ │ ├── README.md │ │ └── compose.yaml ├── docker_image_build │ └── build.yaml ├── kubernetes │ └── helm │ │ ├── README.md │ │ ├── cpu-values.yaml │ │ └── gaudi-values.yaml ├── tests │ ├── test_compose_on_gaudi.sh │ └── test_compose_on_xeon.sh └── ui │ ├── docker │ └── Dockerfile │ └── svelte │ ├── .editorconfig │ ├── .env │ ├── .eslintignore │ ├── .eslintrc.cjs │ ├── .prettierignore │ ├── .prettierrc │ ├── README.md │ ├── package.json │ ├── playwright.config.ts │ ├── postcss.config.cjs │ ├── src │ ├── app.d.ts │ ├── app.html │ ├── app.postcss │ ├── lib │ │ ├── assets │ │ │ └── layout │ │ │ │ └── css │ │ │ │ └── driver.css │ │ ├── modules │ │ │ └── imageList │ │ │ │ └── GenerateImg.svelte │ │ ├── network │ │ │ └── Network.ts │ │ └── shared │ │ │ ├── components │ │ │ ├── header │ │ │ │ └── header.svelte │ │ │ ├── loading │ │ │ │ └── Loading.svelte │ │ │ └── scrollbar │ │ │ │ └── Scrollbar.svelte │ │ │ └── stores │ │ │ └── common │ │ │ └── Store.ts │ └── routes │ │ ├── +layout.svelte │ │ ├── +page.svelte │ │ └── +page.ts │ ├── static │ └── favicon.png │ ├── svelte.config.js │ ├── tailwind.config.cjs │ ├── tests │ └── txt2Img.spec.ts │ ├── tsconfig.json │ └── vite.config.ts ├── Translation ├── Dockerfile ├── README.md ├── assets │ └── img │ │ ├── trans_ui_init.png │ │ ├── trans_ui_select.png │ │ ├── translation-ui-response-example.png │ │ ├── translation-ui-starting-page.png │ │ └── translation_architecture.png ├── docker_compose │ ├── amd │ │ └── gpu │ │ │ └── rocm │ │ │ ├── README.md │ │ │ ├── compose.yaml │ │ │ ├── compose_vllm.yaml │ │ │ ├── set_env.sh │ │ │ └── set_env_vllm.sh │ └── intel │ │ ├── cpu │ │ └── xeon │ │ │ ├── README.md │ │ │ └── compose.yaml │ │ ├── hpu │ │ └── gaudi │ │ │ ├── README.md │ │ │ └── compose.yaml │ │ └── set_env.sh ├── docker_image_build │ └── build.yaml ├── kubernetes │ └── gmc │ │ ├── README.md │ │ ├── translation_gaudi.yaml │ │ └── translation_xeon.yaml ├── tests │ ├── README.md │ ├── test_compose_on_gaudi.sh │ ├── test_compose_on_rocm.sh │ ├── test_compose_on_xeon.sh │ ├── test_compose_vllm_on_rocm.sh │ ├── test_gmc_on_gaudi.sh │ └── test_gmc_on_xeon.sh ├── translation.py └── ui │ ├── docker │ └── Dockerfile │ └── svelte │ ├── .env │ ├── .gitignore │ ├── .npmrc │ ├── README.md │ ├── package.json │ ├── playwright.config.ts │ ├── postcss.config.cjs │ ├── src │ ├── app.d.ts │ ├── app.html │ ├── app.pcss │ ├── lib │ │ ├── assets │ │ │ ├── loadingAnimation.svelte │ │ │ └── summaryLogo.svelte │ │ ├── header.svelte │ │ └── shared │ │ │ ├── Network.ts │ │ │ └── constant.ts │ └── routes │ │ ├── +layout.svelte │ │ ├── +page.svelte │ │ └── types.d.ts │ ├── static │ └── favicon.png │ ├── svelte.config.js │ ├── tailwind.config.cjs │ ├── tests │ └── Translation.spec.ts │ ├── tsconfig.json │ └── vite.config.ts ├── VideoQnA ├── Dockerfile ├── README.md ├── assets │ └── img │ │ └── videoqna.gif ├── docker_compose │ └── intel │ │ └── cpu │ │ └── xeon │ │ ├── README.md │ │ ├── compose.yaml │ │ ├── data │ │ └── op_1_0320241830.mp4 │ │ └── set_env.sh ├── docker_image_build │ └── build.yaml ├── tests │ └── test_compose_on_xeon.sh ├── ui │ ├── docker │ │ └── Dockerfile │ └── ui.py └── videoqna.py ├── VisualQnA ├── Dockerfile ├── README.md ├── assets │ └── img │ │ ├── llava_screenshot1.png │ │ ├── llava_screenshot2.png │ │ ├── visualqna-ui-result-page.png │ │ ├── visualqna-ui-starting-page.png │ │ └── vqa.png ├── benchmark │ └── performance │ │ ├── README.md │ │ ├── benchmark.sh │ │ └── benchmark.yaml ├── docker_compose │ ├── amd │ │ └── gpu │ │ │ └── rocm │ │ │ ├── README.md │ │ │ ├── compose.yaml │ │ │ ├── compose_vllm.yaml │ │ │ ├── set_env.sh │ │ │ └── set_env_vllm.sh │ └── intel │ │ ├── cpu │ │ └── xeon │ │ │ ├── README.md │ │ │ ├── compose.yaml │ │ │ ├── compose_tgi.yaml │ │ │ └── set_env.sh │ │ └── hpu │ │ └── gaudi │ │ ├── README.md │ │ ├── compose.yaml │ │ ├── compose_tgi.yaml │ │ └── set_env.sh ├── docker_image_build │ └── build.yaml ├── kubernetes │ ├── gmc │ │ ├── README.md │ │ ├── visualqna_gaudi.yaml │ │ └── visualqna_xeon.yaml │ └── helm │ │ ├── README.md │ │ ├── cpu-tgi-values.yaml │ │ ├── cpu-values.yaml │ │ ├── gaudi-tgi-values.yaml │ │ └── gaudi-values.yaml ├── tests │ ├── README.md │ ├── test_compose_on_gaudi.sh │ ├── test_compose_on_rocm.sh │ ├── test_compose_on_xeon.sh │ ├── test_compose_tgi_on_gaudi.sh │ ├── test_compose_tgi_on_xeon.sh │ └── test_compose_vllm_on_rocm.sh ├── ui │ ├── docker │ │ └── Dockerfile │ └── svelte │ │ ├── .editorconfig │ │ ├── .env │ │ ├── .eslintignore │ │ ├── .eslintrc.cjs │ │ ├── .prettierignore │ │ ├── .prettierrc │ │ ├── package.json │ │ ├── playwright.config.ts │ │ ├── postcss.config.cjs │ │ ├── src │ │ ├── app.d.ts │ │ ├── app.html │ │ ├── app.postcss │ │ ├── lib │ │ │ ├── assets │ │ │ │ ├── avatar │ │ │ │ │ └── svelte │ │ │ │ │ │ └── Delete.svelte │ │ │ │ ├── chat │ │ │ │ │ └── svelte │ │ │ │ │ │ ├── Assistant.svelte │ │ │ │ │ │ ├── PaperAirplane.svelte │ │ │ │ │ │ └── PersonOutlined.svelte │ │ │ │ ├── header │ │ │ │ │ └── intelLogo.svelte │ │ │ │ ├── imageData │ │ │ │ │ ├── extreme_ironing.png │ │ │ │ │ └── waterview.png │ │ │ │ ├── layout │ │ │ │ │ └── css │ │ │ │ │ │ └── driver.css │ │ │ │ ├── upload │ │ │ │ │ ├── help.svelte │ │ │ │ │ ├── next.svelte │ │ │ │ │ └── previous.svelte │ │ │ │ └── voice │ │ │ │ │ └── svg │ │ │ │ │ ├── paste.svg │ │ │ │ │ └── uploadFile.svg │ │ │ ├── modules │ │ │ │ ├── chat │ │ │ │ │ ├── ChatMessage.svelte │ │ │ │ │ ├── MessageAvatar.svelte │ │ │ │ │ └── MessageTimer.svelte │ │ │ │ ├── frame │ │ │ │ │ └── Layout.svelte │ │ │ │ └── upload │ │ │ │ │ ├── imagePrompt.svelte │ │ │ │ │ ├── upload.svelte │ │ │ │ │ └── uploadImg.svelte │ │ │ ├── network │ │ │ │ ├── chat │ │ │ │ │ └── Network.ts │ │ │ │ └── upload │ │ │ │ │ └── Network.ts │ │ │ └── shared │ │ │ │ ├── Utils.ts │ │ │ │ ├── components │ │ │ │ ├── header │ │ │ │ │ └── header.svelte │ │ │ │ ├── loading │ │ │ │ │ └── Loading.svelte │ │ │ │ └── scrollbar │ │ │ │ │ └── Scrollbar.svelte │ │ │ │ ├── constant │ │ │ │ └── Interface.ts │ │ │ │ └── stores │ │ │ │ └── common │ │ │ │ └── Store.ts │ │ └── routes │ │ │ ├── +layout.svelte │ │ │ ├── +page.svelte │ │ │ └── +page.ts │ │ ├── static │ │ └── favicon.png │ │ ├── svelte.config.js │ │ ├── tailwind.config.cjs │ │ ├── tsconfig.json │ │ └── vite.config.ts └── visualqna.py ├── WorkflowExecAgent ├── README.md ├── docker_compose │ └── intel │ │ └── cpu │ │ └── xeon │ │ └── compose_vllm.yaml ├── docker_image_build │ └── build.yaml ├── tests │ ├── 1_build_images.sh │ ├── 2_start_vllm_service.sh │ ├── 3_launch_and_validate_agent.sh │ ├── README.md │ ├── test_compose_vllm_on_xeon.sh │ └── tool_chat_template_mistral_custom.jinja └── tools │ ├── components │ ├── component.py │ └── workflow.py │ ├── custom_prompt.py │ ├── sdk.py │ ├── tools.py │ ├── tools.yaml │ └── utils │ └── handle_requests.py ├── benchmark.py ├── deploy.py ├── deploy_and_benchmark.py ├── docker_images_list.md ├── pyproject.toml ├── requirements.txt ├── supported_examples.md └── third-party-programs.txt /.gitattributes: -------------------------------------------------------------------------------- 1 | * text=auto eol=lf 2 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/config.yml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | blank_issues_enabled: true 5 | -------------------------------------------------------------------------------- /.github/code_spell_ignore.txt: -------------------------------------------------------------------------------- 1 | ModelIn 2 | modelin 3 | pressEnter -------------------------------------------------------------------------------- /.github/env/_build_image.sh: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2025 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | export VLLM_VER=v0.8.3 5 | export VLLM_FORK_VER=v0.6.6.post1+Gaudi-1.20.0 6 | -------------------------------------------------------------------------------- /.github/license_template.txt: -------------------------------------------------------------------------------- 1 | Copyright (C) 2025 Intel Corporation 2 | SPDX-License-Identifier: Apache-2.0 3 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | **/node_modules 2 | **/.svelte-kit 3 | **/package-lock.json 4 | **/playwright-report/ 5 | **/playwright/.cache/ 6 | **/test-results/ 7 | 8 | __pycache__/ 9 | -------------------------------------------------------------------------------- /.prettierignore: -------------------------------------------------------------------------------- 1 | **/kubernetes/ 2 | -------------------------------------------------------------------------------- /.set_env.sh: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | # 4 | #To anounce the version of the codes, please create a version.txt and have following format. 5 | #VERSION_MAJOR 1 6 | #VERSION_MINOR 0 7 | #VERSION_PATCH 0 8 | 9 | VERSION_FILE="version.txt" 10 | if [ -f $VERSION_FILE ]; then 11 | VER_OPEA_MAJOR=$(grep "VERSION_MAJOR" $VERSION_FILE | cut -d " " -f 2) 12 | VER_OPEA_MINOR=$(grep "VERSION_MINOR" $VERSION_FILE | cut -d " " -f 2) 13 | VER_OPEA_PATCH=$(grep "VERSION_PATCH" $VERSION_FILE | cut -d " " -f 2) 14 | export TAG=$VER_OPEA_MAJOR.$VER_OPEA_MINOR 15 | echo OPEA Version:$TAG 16 | fi 17 | -------------------------------------------------------------------------------- /AgentQnA/assets/img/agent_qna_arch.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AgentQnA/assets/img/agent_qna_arch.png -------------------------------------------------------------------------------- /AgentQnA/assets/img/agent_ui.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AgentQnA/assets/img/agent_ui.png -------------------------------------------------------------------------------- /AgentQnA/assets/img/agent_ui_result.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AgentQnA/assets/img/agent_ui_result.png -------------------------------------------------------------------------------- /AgentQnA/assets/img/opea-agent-setting.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AgentQnA/assets/img/opea-agent-setting.png -------------------------------------------------------------------------------- /AgentQnA/assets/img/opea-agent-test.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AgentQnA/assets/img/opea-agent-test.png -------------------------------------------------------------------------------- /AgentQnA/docker_compose/intel/cpu/xeon/README.md: -------------------------------------------------------------------------------- 1 | # Single node on-prem deployment with Docker Compose on Xeon Scalable processors 2 | 3 | This example showcases a hierarchical multi-agent system for question-answering applications. To deploy the example on Xeon, OpenAI LLM models via API calls are used. For instructions, refer to the deployment guide [here](../../../../README.md). 4 | -------------------------------------------------------------------------------- /AgentQnA/docker_compose/intel/cpu/xeon/compose_remote.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2025 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | services: 5 | worker-rag-agent: 6 | environment: 7 | llm_endpoint_url: ${LLM_ENDPOINT_URL} 8 | api_key: ${OPENAI_API_KEY} 9 | 10 | worker-sql-agent: 11 | environment: 12 | llm_endpoint_url: ${LLM_ENDPOINT_URL} 13 | api_key: ${OPENAI_API_KEY} 14 | 15 | supervisor-react-agent: 16 | environment: 17 | llm_endpoint_url: ${LLM_ENDPOINT_URL} 18 | api_key: ${OPENAI_API_KEY} 19 | -------------------------------------------------------------------------------- /AgentQnA/docker_compose/intel/hpu/gaudi/README.md: -------------------------------------------------------------------------------- 1 | # Single node on-prem deployment AgentQnA on Gaudi 2 | 3 | This example showcases a hierarchical multi-agent system for question-answering applications. To deploy the example on Gaudi using open-source LLMs, refer to the deployment guide [here](../../../../README.md). 4 | -------------------------------------------------------------------------------- /AgentQnA/docker_compose/intel/hpu/gaudi/compose.webtool.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | services: 5 | supervisor-react-agent: 6 | environment: 7 | - tools=/home/user/tools/supervisor_agent_webtools.yaml 8 | - GOOGLE_CSE_ID=${GOOGLE_CSE_ID} 9 | - GOOGLE_API_KEY=${GOOGLE_API_KEY} 10 | -------------------------------------------------------------------------------- /AgentQnA/docker_compose/intel/hpu/gaudi/grafana/provisioning/dashboards/local.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2025 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: 1 5 | 6 | providers: 7 | - name: 'default' 8 | orgId: 1 9 | folder: '' 10 | type: file 11 | disableDeletion: false 12 | updateIntervalSeconds: 10 #how often Grafana will scan for changed dashboards 13 | options: 14 | path: /var/lib/grafana/dashboards 15 | -------------------------------------------------------------------------------- /AgentQnA/docker_image_build/.README: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AgentQnA/docker_image_build/.README -------------------------------------------------------------------------------- /AgentQnA/kubernetes/helm/README.md: -------------------------------------------------------------------------------- 1 | # Deploy AgentQnA on Kubernetes cluster 2 | 3 | - You should have Helm (version >= 3.15) installed. Refer to the [Helm Installation Guide](https://helm.sh/docs/intro/install/) for more information. 4 | - For more deploy options, refer to [helm charts README](https://github.com/opea-project/GenAIInfra/tree/main/helm-charts#readme). 5 | 6 | ## Deploy on Gaudi 7 | 8 | ``` 9 | export HFTOKEN="insert-your-huggingface-token-here" 10 | helm install agentqna oci://ghcr.io/opea-project/charts/agentqna --set global.HUGGINGFACEHUB_API_TOKEN=${HFTOKEN} -f gaudi-values.yaml 11 | ``` 12 | -------------------------------------------------------------------------------- /AgentQnA/tests/sql_agent_test/run_data_split.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # Copyright (C) 2024 Intel Corporation 3 | # SPDX-License-Identifier: Apache-2.0 4 | 5 | DATAPATH=$WORKDIR/TAG-Bench/tag_queries.csv 6 | OUTFOLDER=$WORKDIR/TAG-Bench/query_by_db 7 | python3 split_data.py --path $DATAPATH --output $OUTFOLDER 8 | -------------------------------------------------------------------------------- /AgentQnA/tools/worker_agent_tools.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | search_knowledge_base: 5 | description: Search knowledge base for a given query. Returns text related to the query. 6 | callable_api: worker_agent_tools.py:search_knowledge_base 7 | args_schema: 8 | query: 9 | type: str 10 | description: query 11 | return_output: retrieved_data 12 | -------------------------------------------------------------------------------- /AudioQnA/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | ARG IMAGE_REPO=opea 5 | ARG BASE_TAG=latest 6 | FROM $IMAGE_REPO/comps-base:$BASE_TAG 7 | 8 | COPY ./audioqna.py $HOME/audioqna.py 9 | 10 | ENTRYPOINT ["python", "audioqna.py"] 11 | -------------------------------------------------------------------------------- /AudioQnA/Dockerfile.multilang: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | ARG IMAGE_REPO=opea 5 | ARG BASE_TAG=latest 6 | FROM $IMAGE_REPO/comps-base:$BASE_TAG 7 | 8 | COPY ./audioqna_multilang.py $HOME/audioqna_multilang.py 9 | 10 | ENTRYPOINT ["python", "audioqna_multilang.py"] 11 | -------------------------------------------------------------------------------- /AudioQnA/assets/img/audio_ui.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AudioQnA/assets/img/audio_ui.png -------------------------------------------------------------------------------- /AudioQnA/assets/img/audio_ui_record.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AudioQnA/assets/img/audio_ui_record.png -------------------------------------------------------------------------------- /AudioQnA/assets/img/audioqna.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AudioQnA/assets/img/audioqna.jpg -------------------------------------------------------------------------------- /AudioQnA/benchmark/accuracy/requirements.txt: -------------------------------------------------------------------------------- 1 | datasets 2 | evaluate 3 | jiwer 4 | librosa 5 | pydub 6 | soundfile 7 | torch 8 | transformers 9 | -------------------------------------------------------------------------------- /AudioQnA/benchmark/accuracy/run_acc.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # Copyright (C) 2024 Intel Corporation 3 | # SPDX-License-Identifier: Apache-2.0 4 | 5 | python online_eval.py 6 | -------------------------------------------------------------------------------- /AudioQnA/kubernetes/helm/cpu-multilang-values.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | tgi: 5 | enabled: false 6 | vllm: 7 | enabled: true 8 | 9 | speecht5: 10 | enabled: false 11 | gpt-sovits: 12 | enabled: true 13 | 14 | image: 15 | repository: opea/audioqna-multilang 16 | -------------------------------------------------------------------------------- /AudioQnA/kubernetes/helm/cpu-tgi-values.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | tgi: 5 | enabled: true 6 | vllm: 7 | enabled: false 8 | 9 | speecht5: 10 | enabled: true 11 | gpt-sovits: 12 | enabled: false 13 | -------------------------------------------------------------------------------- /AudioQnA/kubernetes/helm/cpu-values.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | tgi: 5 | enabled: false 6 | vllm: 7 | enabled: true 8 | 9 | speecht5: 10 | enabled: true 11 | gpt-sovits: 12 | enabled: false 13 | -------------------------------------------------------------------------------- /AudioQnA/ui/svelte/.editorconfig: -------------------------------------------------------------------------------- 1 | [*] 2 | indent_style = tab 3 | 4 | [package.json] 5 | indent_style = space 6 | indent_size = 2 7 | 8 | [*.md] 9 | indent_style = space 10 | indent_size = 2 11 | -------------------------------------------------------------------------------- /AudioQnA/ui/svelte/.env: -------------------------------------------------------------------------------- 1 | CHAT_URL = 'http://backend_address:3008/v1/audioqna' 2 | 3 | -------------------------------------------------------------------------------- /AudioQnA/ui/svelte/.eslintignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules 3 | /build 4 | /.svelte-kit 5 | /package 6 | .env 7 | .env.* 8 | !.env.example 9 | 10 | # Ignore files for PNPM, NPM and YARN 11 | pnpm-lock.yaml 12 | package-lock.json 13 | yarn.lock 14 | -------------------------------------------------------------------------------- /AudioQnA/ui/svelte/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | root: true, 3 | parser: "@typescript-eslint/parser", 4 | extends: ["eslint:recommended", "plugin:@typescript-eslint/recommended", "prettier"], 5 | plugins: ["svelte3", "@typescript-eslint", "neverthrow"], 6 | ignorePatterns: ["*.cjs"], 7 | overrides: [{ files: ["*.svelte"], processor: "svelte3/svelte3" }], 8 | settings: { 9 | "svelte3/typescript": () => require("typescript"), 10 | }, 11 | parserOptions: { 12 | sourceType: "module", 13 | ecmaVersion: 2020, 14 | }, 15 | env: { 16 | browser: true, 17 | es2017: true, 18 | node: true, 19 | }, 20 | }; 21 | -------------------------------------------------------------------------------- /AudioQnA/ui/svelte/.prettierignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules 3 | /build 4 | /.svelte-kit 5 | /package 6 | .env 7 | .env.* 8 | !.env.example 9 | 10 | # Ignore files for PNPM, NPM and YARN 11 | pnpm-lock.yaml 12 | package-lock.json 13 | yarn.lock 14 | -------------------------------------------------------------------------------- /AudioQnA/ui/svelte/.prettierrc: -------------------------------------------------------------------------------- 1 | {"pluginSearchDirs": ["."], "overrides": [{"files": "*.svelte", "options": {"parser": "svelte"}}]} 2 | -------------------------------------------------------------------------------- /AudioQnA/ui/svelte/postcss.config.cjs: -------------------------------------------------------------------------------- 1 | const tailwindcss = require("tailwindcss"); 2 | const autoprefixer = require("autoprefixer"); 3 | 4 | const config = { 5 | plugins: [ 6 | //Some plugins, like tailwindcss/nesting, need to run before Tailwind, 7 | tailwindcss(), 8 | //But others, like autoprefixer, need to run after, 9 | autoprefixer, 10 | ], 11 | }; 12 | 13 | module.exports = config; 14 | -------------------------------------------------------------------------------- /AudioQnA/ui/svelte/src/lib/assets/icons/png/audio1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AudioQnA/ui/svelte/src/lib/assets/icons/png/audio1.png -------------------------------------------------------------------------------- /AudioQnA/ui/svelte/src/lib/assets/icons/png/audio2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AudioQnA/ui/svelte/src/lib/assets/icons/png/audio2.png -------------------------------------------------------------------------------- /AudioQnA/ui/svelte/src/lib/assets/icons/svg/stop-recording.svg: -------------------------------------------------------------------------------- 1 | 3 | 6 | 7 | -------------------------------------------------------------------------------- /AudioQnA/ui/svelte/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AudioQnA/ui/svelte/static/favicon.png -------------------------------------------------------------------------------- /AudioQnA/ui/svelte/tailwind.config.cjs: -------------------------------------------------------------------------------- 1 | const config = { 2 | content: ["./src/**/*.{html,js,svelte,ts}"], 3 | 4 | theme: { 5 | extend: {}, 6 | }, 7 | 8 | plugins: [require("daisyui"), require("@tailwindcss/typography")], 9 | }; 10 | 11 | module.exports = config; 12 | -------------------------------------------------------------------------------- /AudioQnA/ui/svelte/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./.svelte-kit/tsconfig.json", 3 | "compilerOptions": { 4 | "allowJs": true, 5 | "checkJs": true, 6 | "esModuleInterop": true, 7 | "forceConsistentCasingInFileNames": true, 8 | "resolveJsonModule": true, 9 | "skipLibCheck": true, 10 | "sourceMap": true, 11 | "strict": true 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /AvatarChatbot/.gitignore: -------------------------------------------------------------------------------- 1 | *.safetensors 2 | *.bin 3 | *.model 4 | *.log 5 | docker_compose/intel/cpu/xeon/data 6 | docker_compose/intel/hpu/gaudi/data 7 | inputs/ 8 | outputs/ 9 | -------------------------------------------------------------------------------- /AvatarChatbot/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | ARG IMAGE_REPO=opea 5 | ARG BASE_TAG=latest 6 | FROM $IMAGE_REPO/comps-base:$BASE_TAG 7 | 8 | COPY ./avatarchatbot.py $HOME/avatarchatbot.py 9 | 10 | ENTRYPOINT ["python", "avatarchatbot.py"] 11 | -------------------------------------------------------------------------------- /AvatarChatbot/assets/audio/eg3_ref.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AvatarChatbot/assets/audio/eg3_ref.wav -------------------------------------------------------------------------------- /AvatarChatbot/assets/img/UI.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AvatarChatbot/assets/img/UI.png -------------------------------------------------------------------------------- /AvatarChatbot/assets/img/avatar1.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AvatarChatbot/assets/img/avatar1.jpg -------------------------------------------------------------------------------- /AvatarChatbot/assets/img/avatar2.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AvatarChatbot/assets/img/avatar2.jpg -------------------------------------------------------------------------------- /AvatarChatbot/assets/img/avatar3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AvatarChatbot/assets/img/avatar3.png -------------------------------------------------------------------------------- /AvatarChatbot/assets/img/avatar4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AvatarChatbot/assets/img/avatar4.png -------------------------------------------------------------------------------- /AvatarChatbot/assets/img/avatar5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AvatarChatbot/assets/img/avatar5.png -------------------------------------------------------------------------------- /AvatarChatbot/assets/img/avatar6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AvatarChatbot/assets/img/avatar6.png -------------------------------------------------------------------------------- /AvatarChatbot/assets/img/design.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AvatarChatbot/assets/img/design.png -------------------------------------------------------------------------------- /AvatarChatbot/assets/img/flowchart.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AvatarChatbot/assets/img/flowchart.png -------------------------------------------------------------------------------- /AvatarChatbot/assets/img/gaudi.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AvatarChatbot/assets/img/gaudi.png -------------------------------------------------------------------------------- /AvatarChatbot/assets/img/opea_gh_qr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AvatarChatbot/assets/img/opea_gh_qr.png -------------------------------------------------------------------------------- /AvatarChatbot/assets/img/opea_qr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AvatarChatbot/assets/img/opea_qr.png -------------------------------------------------------------------------------- /AvatarChatbot/assets/img/xeon.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AvatarChatbot/assets/img/xeon.jpg -------------------------------------------------------------------------------- /AvatarChatbot/assets/outputs/result_max_tokens_1024.mp4: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AvatarChatbot/assets/outputs/result_max_tokens_1024.mp4 -------------------------------------------------------------------------------- /AvatarChatbot/assets/outputs/result_max_tokens_64.mp4: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/AvatarChatbot/assets/outputs/result_max_tokens_64.mp4 -------------------------------------------------------------------------------- /AvatarChatbot/tests/README.md: -------------------------------------------------------------------------------- 1 | # AvatarChatbot E2E test scripts 2 | 3 | ## Set the required environment variable 4 | 5 | ```bash 6 | export HF_TOKEN="Your_Huggingface_API_Token" 7 | ``` 8 | 9 | ## Run test 10 | 11 | On Intel Xeon with TGI: 12 | 13 | ```bash 14 | bash test_compose_on_xeon.sh 15 | ``` 16 | 17 | On Intel Gaudi with TGI: 18 | 19 | ```bash 20 | bash test_compose_on_gaudi.sh 21 | ``` 22 | 23 | On AMD ROCm with TGI: 24 | 25 | ```bash 26 | bash test_compose_on_rocm.sh 27 | ``` 28 | -------------------------------------------------------------------------------- /ChatQnA/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | ARG IMAGE_REPO=opea 5 | ARG BASE_TAG=latest 6 | FROM $IMAGE_REPO/comps-base:$BASE_TAG 7 | 8 | COPY ./chatqna.py $HOME/chatqna.py 9 | COPY ./entrypoint.sh $HOME/entrypoint.sh 10 | 11 | ENTRYPOINT ["bash", "entrypoint.sh"] 12 | -------------------------------------------------------------------------------- /ChatQnA/assets/img/chat_ui_init.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ChatQnA/assets/img/chat_ui_init.png -------------------------------------------------------------------------------- /ChatQnA/assets/img/chat_ui_response.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ChatQnA/assets/img/chat_ui_response.png -------------------------------------------------------------------------------- /ChatQnA/assets/img/chat_ui_upload.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ChatQnA/assets/img/chat_ui_upload.png -------------------------------------------------------------------------------- /ChatQnA/assets/img/chatqna_architecture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ChatQnA/assets/img/chatqna_architecture.png -------------------------------------------------------------------------------- /ChatQnA/assets/img/chatqna_dashboards.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ChatQnA/assets/img/chatqna_dashboards.png -------------------------------------------------------------------------------- /ChatQnA/assets/img/chatqna_flow_chart.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ChatQnA/assets/img/chatqna_flow_chart.png -------------------------------------------------------------------------------- /ChatQnA/assets/img/conversation_ui_init.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ChatQnA/assets/img/conversation_ui_init.png -------------------------------------------------------------------------------- /ChatQnA/assets/img/conversation_ui_response.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ChatQnA/assets/img/conversation_ui_response.png -------------------------------------------------------------------------------- /ChatQnA/assets/img/conversation_ui_upload.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ChatQnA/assets/img/conversation_ui_upload.png -------------------------------------------------------------------------------- /ChatQnA/assets/img/tgi_dashboard.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ChatQnA/assets/img/tgi_dashboard.png -------------------------------------------------------------------------------- /ChatQnA/assets/img/ui-result-page-faqgen.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ChatQnA/assets/img/ui-result-page-faqgen.png -------------------------------------------------------------------------------- /ChatQnA/assets/img/ui-result-page.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ChatQnA/assets/img/ui-result-page.png -------------------------------------------------------------------------------- /ChatQnA/assets/img/ui-starting-page.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ChatQnA/assets/img/ui-starting-page.png -------------------------------------------------------------------------------- /ChatQnA/benchmark/accuracy/process_crud_dataset.py: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | import os 5 | 6 | path = os.path.join(os.path.dirname(__file__), "./data/80000_docs") 7 | for file in os.listdir(path): 8 | src_file = os.path.join(path, file) 9 | os.rename(src_file, src_file + ".txt") 10 | -------------------------------------------------------------------------------- /ChatQnA/benchmark/accuracy_faqgen/get_context.py: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | import json 5 | import os 6 | 7 | import pandas as pd 8 | 9 | data_path = "./data" 10 | data = pd.read_parquet(os.path.join(data_path, "squad_v2/squad_v2/validation-00000-of-00001.parquet")) 11 | sq_context = list(data["context"].unique()) 12 | sq_context_d = dict() 13 | for i in range(len(sq_context)): 14 | sq_context_d[i] = sq_context[i] 15 | 16 | with open(os.path.join(data_path, "sqv2_context.json"), "w") as outfile: 17 | json.dump(sq_context_d, outfile) 18 | -------------------------------------------------------------------------------- /ChatQnA/benchmark/accuracy_faqgen/run_acc.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # Copyright (C) 2024 Intel Corporation 3 | # SPDX-License-Identifier: Apache-2.0 4 | 5 | python evaluate.py 6 | -------------------------------------------------------------------------------- /ChatQnA/docker_compose/intel/cpu/xeon/grafana/provisioning/dashboards/local.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2025 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: 1 5 | 6 | providers: 7 | - name: 'default' 8 | orgId: 1 9 | folder: '' 10 | type: file 11 | disableDeletion: false 12 | updateIntervalSeconds: 10 #how often Grafana will scan for changed dashboards 13 | options: 14 | path: /var/lib/grafana/dashboards 15 | -------------------------------------------------------------------------------- /ChatQnA/docker_compose/intel/hpu/gaudi/grafana/provisioning/dashboards/local.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2025 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: 1 5 | 6 | providers: 7 | - name: 'default' 8 | orgId: 1 9 | folder: '' 10 | type: file 11 | disableDeletion: false 12 | updateIntervalSeconds: 10 #how often Grafana will scan for changed dashboards 13 | options: 14 | path: /var/lib/grafana/dashboards 15 | -------------------------------------------------------------------------------- /ChatQnA/entrypoint.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # Copyright (C) 2025 Intel Corporation 3 | # SPDX-License-Identifier: Apache-2.0 4 | 5 | chatqna_arg=$CHATQNA_TYPE 6 | 7 | if [[ $chatqna_arg == "CHATQNA_FAQGEN" ]]; then 8 | python chatqna.py --faqgen 9 | elif [[ $chatqna_arg == "CHATQNA_NO_RERANK" ]]; then 10 | python chatqna.py --without-rerank 11 | elif [[ $chatqna_arg == "CHATQNA_GUARDRAILS" ]]; then 12 | python chatqna.py --with-guardrails 13 | else 14 | python chatqna.py 15 | fi 16 | -------------------------------------------------------------------------------- /ChatQnA/kubernetes/helm/cpu-milvus-values.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2025 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | redis-vector-db: 5 | enabled: false 6 | milvus: 7 | enabled: true 8 | 9 | data-prep: 10 | DATAPREP_BACKEND: "MILVUS" 11 | COLLECTION_NAME: "rag_milvus" 12 | retriever-usvc: 13 | RETRIEVER_BACKEND: "MILVUS" 14 | COLLECTION_NAME: "rag_milvus" 15 | -------------------------------------------------------------------------------- /ChatQnA/kubernetes/helm/cpu-qdrant-values.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2025 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | redis-vector-db: 5 | enabled: false 6 | qdrant: 7 | enabled: true 8 | 9 | data-prep: 10 | DATAPREP_BACKEND: "QDRANT" 11 | retriever-usvc: 12 | RETRIEVER_BACKEND: "QDRANT" 13 | -------------------------------------------------------------------------------- /ChatQnA/kubernetes/helm/cpu-values.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2025 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | vllm: 5 | LLM_MODEL_ID: meta-llama/Meta-Llama-3-8B-Instruct 6 | # Uncomment the following model specific settings for DeepSeek models 7 | #VLLM_CPU_KVCACHE_SPACE: 40 8 | #resources: 9 | # requests: 10 | # memory: 60Gi # 40G for KV cache, and 20G for DeepSeek-R1-Distill-Qwen-7B, need to adjust it for other models 11 | -------------------------------------------------------------------------------- /ChatQnA/kubernetes/helm/faqgen-cpu-tgi-values.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2025 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | CHATQNA_TYPE: "CHATQNA_FAQGEN" 5 | llm-uservice: 6 | enabled: true 7 | image: 8 | repository: opea/llm-faqgen 9 | LLM_MODEL_ID: meta-llama/Meta-Llama-3-8B-Instruct 10 | FAQGEN_BACKEND: "TGI" 11 | service: 12 | port: 80 13 | vllm: 14 | enabled: false 15 | tgi: 16 | enabled: true 17 | -------------------------------------------------------------------------------- /ChatQnA/kubernetes/helm/faqgen-cpu-values.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2025 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | CHATQNA_TYPE: "CHATQNA_FAQGEN" 5 | llm-uservice: 6 | enabled: true 7 | image: 8 | repository: opea/llm-faqgen 9 | LLM_MODEL_ID: meta-llama/Meta-Llama-3-8B-Instruct 10 | FAQGEN_BACKEND: "vLLM" 11 | service: 12 | port: 80 13 | -------------------------------------------------------------------------------- /ChatQnA/kubernetes/helm/norerank-values.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2025 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | CHATQNA_TYPE: "CHATQNA_NO_RERANK" 5 | 6 | teirerank: 7 | enabled: false 8 | -------------------------------------------------------------------------------- /ChatQnA/ui/docker/Dockerfile.react: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | # Use node 20.11.1 as the base image 5 | FROM node:20.11.1 as vite-app 6 | 7 | COPY react /usr/app/react 8 | WORKDIR /usr/app/react 9 | 10 | 11 | RUN ["npm", "install"] 12 | RUN ["npm", "run", "build"] 13 | 14 | 15 | FROM nginx:alpine 16 | 17 | COPY --from=vite-app /usr/app/react/dist /usr/share/nginx/html 18 | COPY ./react/env.sh /docker-entrypoint.d/env.sh 19 | 20 | COPY ./react/nginx.conf /etc/nginx/conf.d/default.conf 21 | RUN chmod +x /docker-entrypoint.d/env.sh 22 | -------------------------------------------------------------------------------- /ChatQnA/ui/react/.env: -------------------------------------------------------------------------------- 1 | VITE_BACKEND_SERVICE_ENDPOINT=http://backend_address:8888/v1/chatqna 2 | VITE_DATA_PREP_SERVICE_URL=http://backend_address:6007/v1/dataprep/ingest 3 | -------------------------------------------------------------------------------- /ChatQnA/ui/react/.env.production: -------------------------------------------------------------------------------- 1 | VITE_BACKEND_SERVICE_ENDPOINT=APP_BACKEND_SERVICE_ENDPOINT 2 | VITE_DATA_PREP_SERVICE_URL=APP_DATA_PREP_SERVICE_URL 3 | -------------------------------------------------------------------------------- /ChatQnA/ui/react/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | root: true, 3 | env: { browser: true, es2020: true }, 4 | extends: ["eslint:recommended", "plugin:@typescript-eslint/recommended", "plugin:react-hooks/recommended"], 5 | ignorePatterns: ["dist", ".eslintrc.cjs"], 6 | parser: "@typescript-eslint/parser", 7 | plugins: ["react-refresh"], 8 | rules: { 9 | "react-refresh/only-export-components": ["warn", { allowConstantExport: true }], 10 | }, 11 | }; 12 | -------------------------------------------------------------------------------- /ChatQnA/ui/react/.gitignore: -------------------------------------------------------------------------------- 1 | # Logs 2 | logs 3 | *.log 4 | npm-debug.log* 5 | yarn-debug.log* 6 | yarn-error.log* 7 | pnpm-debug.log* 8 | lerna-debug.log* 9 | 10 | node_modules 11 | dist 12 | dist-ssr 13 | *.local 14 | 15 | # Editor directories and files 16 | .vscode/* 17 | !.vscode/extensions.json 18 | .idea 19 | .DS_Store 20 | *.suo 21 | *.ntvs* 22 | *.njsproj 23 | *.sln 24 | *.sw? 25 | -------------------------------------------------------------------------------- /ChatQnA/ui/react/env.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # Copyright (C) 2024 Intel Corporation 3 | # SPDX-License-Identifier: Apache-2.0 4 | 5 | for i in $(env | grep APP_) #// Make sure to use the prefix MY_APP_ if you have any other prefix in env.production file variable name replace it with MY_APP_ 6 | do 7 | key=$(echo $i | cut -d '=' -f 1) 8 | value=$(echo $i | cut -d '=' -f 2-) 9 | echo $key=$value 10 | # sed All files 11 | # find /usr/share/nginx/html -type f -exec sed -i "s|${key}|${value}|g" '{}' + 12 | 13 | # sed JS and CSS only 14 | find /usr/share/nginx/html -type f \( -name '*.js' -o -name '*.css' \) -exec sed -i "s|${key}|${value}|g" '{}' + 15 | done 16 | -------------------------------------------------------------------------------- /ChatQnA/ui/react/index.html: -------------------------------------------------------------------------------- 1 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | Conversations UI 13 | 14 | 15 |
16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /ChatQnA/ui/react/nginx.conf: -------------------------------------------------------------------------------- 1 | server { 2 | listen 80; 3 | 4 | gzip on; 5 | gzip_proxied any; 6 | gzip_comp_level 6; 7 | gzip_buffers 16 8k; 8 | gzip_http_version 1.1; 9 | gzip_types font/woff2 text/css application/javascript application/json application/font-woff application/font-tff image/gif image/png image/svg+xml application/octet-stream; 10 | 11 | location / { 12 | root /usr/share/nginx/html; 13 | index index.html index.htm; 14 | try_files $uri $uri/ /index.html =404; 15 | 16 | location ~* \.(gif|jpe?g|png|webp|ico|svg|css|js|mp4|woff2)$ { 17 | expires 1d; 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /ChatQnA/ui/react/postcss.config.cjs: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | plugins: { 3 | "postcss-preset-mantine": {}, 4 | "postcss-simple-vars": { 5 | variables: { 6 | "mantine-breakpoint-xs": "36em", 7 | "mantine-breakpoint-sm": "48em", 8 | "mantine-breakpoint-md": "62em", 9 | "mantine-breakpoint-lg": "75em", 10 | "mantine-breakpoint-xl": "88em", 11 | }, 12 | }, 13 | }, 14 | }; 15 | -------------------------------------------------------------------------------- /ChatQnA/ui/react/src/__tests__/util.test.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import { describe, expect, test } from "vitest"; 5 | import { getCurrentTimeStamp, uuidv4 } from "../common/util"; 6 | 7 | describe("unit tests", () => { 8 | test("check UUID is of length 36", () => { 9 | expect(uuidv4()).toHaveLength(36); 10 | }); 11 | test("check TimeStamp generated is of unix", () => { 12 | expect(getCurrentTimeStamp()).toBe(Math.floor(Date.now() / 1000)); 13 | }); 14 | }); 15 | -------------------------------------------------------------------------------- /ChatQnA/ui/react/src/common/client.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import axios from "axios"; 5 | 6 | //add iterceptors to add any request headers 7 | 8 | export default axios; 9 | -------------------------------------------------------------------------------- /ChatQnA/ui/react/src/common/util.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | export const getCurrentTimeStamp = () => { 5 | return Math.floor(Date.now() / 1000); 6 | }; 7 | 8 | export const uuidv4 = () => { 9 | return "10000000-1000-4000-8000-100000000000".replace(/[018]/g, (c) => 10 | (+c ^ (crypto.getRandomValues(new Uint8Array(1))[0] & (15 >> (+c / 4)))).toString(16), 11 | ); 12 | }; 13 | -------------------------------------------------------------------------------- /ChatQnA/ui/react/src/components/Message/conversationMessage.module.scss: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | @import "../../styles/styles"; 5 | 6 | .conversationMessage { 7 | @include flex(column, nowrap, flex-start, flex-start); 8 | margin-top: 16px; 9 | padding: 0 32px; 10 | width: 100%; 11 | 12 | & > * { 13 | width: 100%; 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /ChatQnA/ui/react/src/config.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | export const DATA_PREP_URL = import.meta.env.VITE_DATA_PREP_SERVICE_URL; 5 | export const CHAT_QNA_URL = import.meta.env.VITE_BACKEND_SERVICE_ENDPOINT; 6 | -------------------------------------------------------------------------------- /ChatQnA/ui/react/src/index.scss: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | @import "@mantine/core/styles.css"; 5 | 6 | :root { 7 | font-family: Inter, system-ui, Avenir, Helvetica, Arial, sans-serif; 8 | line-height: 1.5; 9 | font-weight: 400; 10 | } 11 | 12 | html, 13 | body { 14 | position: absolute; 15 | top: 0; 16 | left: 0; 17 | width: 100%; 18 | height: 100%; 19 | overflow: hidden; 20 | } 21 | -------------------------------------------------------------------------------- /ChatQnA/ui/react/src/main.tsx: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import React from "react" 5 | import ReactDOM from "react-dom/client" 6 | import App from "./App.tsx" 7 | import "./index.scss" 8 | import { Provider } from 'react-redux' 9 | import { store } from "./redux/store.ts" 10 | 11 | ReactDOM.createRoot(document.getElementById("root")!).render( 12 | 13 | 14 | 15 | 16 | 17 | ) 18 | -------------------------------------------------------------------------------- /ChatQnA/ui/react/src/redux/User/user.d.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | export interface User { 5 | name: string | null; 6 | } 7 | -------------------------------------------------------------------------------- /ChatQnA/ui/react/src/styles/components/_context.scss: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ChatQnA/ui/react/src/styles/components/_context.scss -------------------------------------------------------------------------------- /ChatQnA/ui/react/src/styles/components/_sidebar.scss: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | @import "../layout/flex"; 5 | 6 | @mixin sidebar { 7 | @include flex(column, nowrap, flex-start, flex-start); 8 | } 9 | -------------------------------------------------------------------------------- /ChatQnA/ui/react/src/styles/components/content.scss: -------------------------------------------------------------------------------- 1 | @mixin textWrapEllipsis { 2 | text-overflow: ellipsis; 3 | white-space: nowrap; 4 | overflow: hidden; 5 | } 6 | -------------------------------------------------------------------------------- /ChatQnA/ui/react/src/styles/layout/_basics.scss: -------------------------------------------------------------------------------- 1 | @mixin absolutes { 2 | position: absolute; 3 | top: 0; 4 | left: 0; 5 | width: 100%; 6 | height: 100%; 7 | } 8 | -------------------------------------------------------------------------------- /ChatQnA/ui/react/src/styles/layout/_flex.scss: -------------------------------------------------------------------------------- 1 | @mixin flex($direction: row, $wrap: nowrap, $alignItems: center, $justifyContent: center) { 2 | display: flex; 3 | flex-flow: $direction $wrap; 4 | align-items: $alignItems; 5 | justify-content: $justifyContent; 6 | } 7 | -------------------------------------------------------------------------------- /ChatQnA/ui/react/src/styles/styles.scss: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | @import "layout/flex"; 5 | @import "layout/basics"; 6 | -------------------------------------------------------------------------------- /ChatQnA/ui/react/src/vite-env.d.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | /// 5 | -------------------------------------------------------------------------------- /ChatQnA/ui/react/tsconfig.node.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "composite": true, 4 | "skipLibCheck": true, 5 | "module": "ESNext", 6 | "moduleResolution": "bundler", 7 | "allowSyntheticDefaultImports": true, 8 | "strict": true 9 | }, 10 | "include": ["vite.config.ts"] 11 | } 12 | -------------------------------------------------------------------------------- /ChatQnA/ui/react/vite.config.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import { defineConfig } from "vitest/config"; 5 | import react from "@vitejs/plugin-react"; 6 | 7 | // https://vitejs.dev/config/ 8 | export default defineConfig({ 9 | css: { 10 | preprocessorOptions: { 11 | scss: { 12 | additionalData: `@import "./src/styles/styles.scss";`, 13 | }, 14 | }, 15 | }, 16 | plugins: [react()], 17 | server: { 18 | port: 80, 19 | }, 20 | test: { 21 | globals: true, 22 | environment: "jsdom", 23 | }, 24 | define: { 25 | "import.meta.env": process.env, 26 | }, 27 | }); 28 | -------------------------------------------------------------------------------- /ChatQnA/ui/svelte/.editorconfig: -------------------------------------------------------------------------------- 1 | [*] 2 | indent_style = tab 3 | 4 | [package.json] 5 | indent_style = space 6 | indent_size = 2 7 | 8 | [*.md] 9 | indent_style = space 10 | indent_size = 2 11 | -------------------------------------------------------------------------------- /ChatQnA/ui/svelte/.env: -------------------------------------------------------------------------------- 1 | CHAT_BASE_URL = '/v1/chatqna' 2 | 3 | UPLOAD_FILE_BASE_URL = '/v1/dataprep/ingest' 4 | 5 | GET_FILE = '/v1/dataprep/get' 6 | 7 | DELETE_FILE = '/v1/dataprep/delete' 8 | -------------------------------------------------------------------------------- /ChatQnA/ui/svelte/.eslintignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules 3 | /build 4 | /.svelte-kit 5 | /package 6 | .env 7 | .env.* 8 | !.env.example 9 | 10 | # Ignore files for PNPM, NPM and YARN 11 | pnpm-lock.yaml 12 | package-lock.json 13 | yarn.lock 14 | -------------------------------------------------------------------------------- /ChatQnA/ui/svelte/.prettierignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules 3 | /build 4 | /.svelte-kit 5 | /package 6 | .env 7 | .env.* 8 | !.env.example 9 | 10 | # Ignore files for PNPM, NPM and YARN 11 | pnpm-lock.yaml 12 | package-lock.json 13 | yarn.lock 14 | -------------------------------------------------------------------------------- /ChatQnA/ui/svelte/.prettierrc: -------------------------------------------------------------------------------- 1 | {"pluginSearchDirs": ["."], "overrides": [{"files": "*.svelte", "options": {"parser": "svelte"}}]} 2 | -------------------------------------------------------------------------------- /ChatQnA/ui/svelte/src/lib/assets/upload/loading-button.svelte: -------------------------------------------------------------------------------- 1 | 5 | 6 | 12 | 20 | 25 | 26 | -------------------------------------------------------------------------------- /ChatQnA/ui/svelte/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ChatQnA/ui/svelte/static/favicon.png -------------------------------------------------------------------------------- /ChatQnA/ui/svelte/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./.svelte-kit/tsconfig.json", 3 | "compilerOptions": { 4 | "allowJs": true, 5 | "checkJs": true, 6 | "esModuleInterop": true, 7 | "forceConsistentCasingInFileNames": true, 8 | "resolveJsonModule": true, 9 | "skipLibCheck": true, 10 | "sourceMap": true, 11 | "strict": true, 12 | "module": "ESNext", 13 | "target": "ES6", 14 | "outDir": "./dist" 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /CodeGen/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | ARG IMAGE_REPO=opea 5 | ARG BASE_TAG=latest 6 | FROM $IMAGE_REPO/comps-base:$BASE_TAG 7 | 8 | COPY ./codegen.py $HOME/codegen.py 9 | 10 | ENTRYPOINT ["python", "codegen.py"] 11 | -------------------------------------------------------------------------------- /CodeGen/assets/img/codeGen_monitoring_ui.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeGen/assets/img/codeGen_monitoring_ui.png -------------------------------------------------------------------------------- /CodeGen/assets/img/codeGen_ui_init.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeGen/assets/img/codeGen_ui_init.jpg -------------------------------------------------------------------------------- /CodeGen/assets/img/codeGen_ui_response.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeGen/assets/img/codeGen_ui_response.png -------------------------------------------------------------------------------- /CodeGen/assets/img/codegen_architecture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeGen/assets/img/codegen_architecture.png -------------------------------------------------------------------------------- /CodeGen/assets/img/codegen_auto_complete.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeGen/assets/img/codegen_auto_complete.jpg -------------------------------------------------------------------------------- /CodeGen/assets/img/codegen_copilot.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeGen/assets/img/codegen_copilot.png -------------------------------------------------------------------------------- /CodeGen/assets/img/codegen_customize.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeGen/assets/img/codegen_customize.png -------------------------------------------------------------------------------- /CodeGen/assets/img/codegen_dialog.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeGen/assets/img/codegen_dialog.png -------------------------------------------------------------------------------- /CodeGen/assets/img/codegen_endpoint.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeGen/assets/img/codegen_endpoint.png -------------------------------------------------------------------------------- /CodeGen/assets/img/codegen_gradio_ui_dataprep.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeGen/assets/img/codegen_gradio_ui_dataprep.png -------------------------------------------------------------------------------- /CodeGen/assets/img/codegen_gradio_ui_main.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeGen/assets/img/codegen_gradio_ui_main.png -------------------------------------------------------------------------------- /CodeGen/assets/img/codegen_gradio_ui_query.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeGen/assets/img/codegen_gradio_ui_query.png -------------------------------------------------------------------------------- /CodeGen/assets/img/codegen_gradio_ui_rm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeGen/assets/img/codegen_gradio_ui_rm.png -------------------------------------------------------------------------------- /CodeGen/assets/img/codegen_icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeGen/assets/img/codegen_icon.png -------------------------------------------------------------------------------- /CodeGen/assets/img/codegen_multi_line.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeGen/assets/img/codegen_multi_line.png -------------------------------------------------------------------------------- /CodeGen/assets/img/codegen_qna.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeGen/assets/img/codegen_qna.png -------------------------------------------------------------------------------- /CodeGen/assets/img/codegen_react.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeGen/assets/img/codegen_react.png -------------------------------------------------------------------------------- /CodeGen/assets/img/codegen_select_code.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeGen/assets/img/codegen_select_code.png -------------------------------------------------------------------------------- /CodeGen/assets/img/codegen_settings.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeGen/assets/img/codegen_settings.png -------------------------------------------------------------------------------- /CodeGen/assets/img/codegen_single_line.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeGen/assets/img/codegen_single_line.png -------------------------------------------------------------------------------- /CodeGen/assets/img/codegen_suggestion.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeGen/assets/img/codegen_suggestion.png -------------------------------------------------------------------------------- /CodeGen/assets/img/ui-result-page.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeGen/assets/img/ui-result-page.png -------------------------------------------------------------------------------- /CodeGen/assets/img/ui-starting-page.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeGen/assets/img/ui-starting-page.png -------------------------------------------------------------------------------- /CodeGen/benchmark/accuracy/main.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | # -*- coding: utf-8 -*- 3 | # Copyright (C) 2024 Intel Corporation 4 | # SPDX-License-Identifier: Apache-2.0 5 | 6 | # 7 | from evals.evaluation.bigcode_evaluation_harness import evaluate, setup_parser 8 | 9 | 10 | def main(): 11 | eval_args = setup_parser() 12 | results = evaluate(eval_args) 13 | print(results) 14 | 15 | 16 | if __name__ == "__main__": 17 | main() 18 | -------------------------------------------------------------------------------- /CodeGen/benchmark/accuracy/run_acc.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # Copyright (C) 2024 Intel Corporation 4 | # SPDX-License-Identifier: Apache-2.0 5 | 6 | python main.py --model $1 \ 7 | --tasks humaneval \ 8 | --codegen_url $2 \ 9 | --max_length_generation 2048 \ 10 | --batch_size 1 \ 11 | --save_generations \ 12 | --save_references \ 13 | --allow_code_execution 14 | -------------------------------------------------------------------------------- /CodeGen/kubernetes/helm/cpu-tgi-values.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | tgi: 5 | enabled: true 6 | vllm: 7 | enabled: false 8 | llm-uservice: 9 | TEXTGEN_BACKEND: TGI 10 | -------------------------------------------------------------------------------- /CodeGen/kubernetes/helm/cpu-values.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | tgi: 5 | enabled: false 6 | vllm: 7 | enabled: true 8 | llm-uservice: 9 | TEXTGEN_BACKEND: vLLM 10 | -------------------------------------------------------------------------------- /CodeGen/tests/README.md: -------------------------------------------------------------------------------- 1 | # CodeGen E2E test scripts 2 | 3 | ## Set the required environment variable 4 | 5 | ```bash 6 | export HF_TOKEN="Your_Huggingface_API_Token" 7 | ``` 8 | 9 | ## Run test 10 | 11 | On Intel Xeon with TGI: 12 | 13 | ```bash 14 | bash test_compose_on_xeon.sh 15 | ``` 16 | 17 | On Intel Gaudi with TGI: 18 | 19 | ```bash 20 | bash test_compose_on_gaudi.sh 21 | ``` 22 | 23 | On AMD ROCm with TGI: 24 | 25 | ```bash 26 | bash test_compose_on_rocm.sh 27 | ``` 28 | 29 | On AMD ROCm with vLLM: 30 | 31 | ```bash 32 | bash test_compose_vllm_on_rocm.sh 33 | ``` 34 | -------------------------------------------------------------------------------- /CodeGen/ui/docker/Dockerfile.react: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | # Use node 20.11.1 as the base image 5 | FROM node:20.11.1 as vite-app 6 | 7 | COPY react /usr/app/react 8 | WORKDIR /usr/app/react 9 | 10 | 11 | RUN ["npm", "install"] 12 | RUN ["npm", "run", "build"] 13 | 14 | 15 | FROM nginx:alpine 16 | 17 | COPY --from=vite-app /usr/app/react/dist /usr/share/nginx/html 18 | COPY ./react/env.sh /docker-entrypoint.d/env.sh 19 | 20 | COPY ./react/nginx.conf /etc/nginx/conf.d/default.conf 21 | RUN chmod +x /docker-entrypoint.d/env.sh 22 | -------------------------------------------------------------------------------- /CodeGen/ui/gradio/requirements.txt: -------------------------------------------------------------------------------- 1 | gradio==5.22.0 2 | numpy==1.26.4 3 | opencv-python==4.10.0.82 4 | Pillow==10.3.0 5 | -------------------------------------------------------------------------------- /CodeGen/ui/react/.env: -------------------------------------------------------------------------------- 1 | VITE_CODE_GEN_URL=http://ip_address:7778/v1/codegen 2 | -------------------------------------------------------------------------------- /CodeGen/ui/react/.env.production: -------------------------------------------------------------------------------- 1 | VITE_CODE_GEN_URL=APP_CODE_GEN_URL 2 | -------------------------------------------------------------------------------- /CodeGen/ui/react/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | root: true, 3 | env: { browser: true, es2020: true }, 4 | extends: ["eslint:recommended", "plugin:@typescript-eslint/recommended", "plugin:react-hooks/recommended"], 5 | ignorePatterns: ["dist", ".eslintrc.cjs"], 6 | parser: "@typescript-eslint/parser", 7 | plugins: ["react-refresh"], 8 | rules: { 9 | "react-refresh/only-export-components": ["warn", { allowConstantExport: true }], 10 | }, 11 | }; 12 | -------------------------------------------------------------------------------- /CodeGen/ui/react/.gitignore: -------------------------------------------------------------------------------- 1 | # Logs 2 | logs 3 | *.log 4 | npm-debug.log* 5 | yarn-debug.log* 6 | yarn-error.log* 7 | pnpm-debug.log* 8 | lerna-debug.log* 9 | 10 | node_modules 11 | dist 12 | dist-ssr 13 | *.local 14 | 15 | # Editor directories and files 16 | .vscode/* 17 | !.vscode/extensions.json 18 | .idea 19 | .DS_Store 20 | *.suo 21 | *.ntvs* 22 | *.njsproj 23 | *.sln 24 | *.sw? 25 | -------------------------------------------------------------------------------- /CodeGen/ui/react/README.md: -------------------------------------------------------------------------------- 1 | # Code Gen 2 | 3 | ## 📸 Project Screenshots 4 | 5 | ![project-screenshot](../../assets/img/codegen_react.png) 6 | 7 | ## 🧐 Features 8 | 9 | Here're some of the project's features: 10 | 11 | - Generate code: generate the corresponding code based on the current user's input. 12 | 13 | ## 🛠️ Get it Running 14 | 15 | 1. Clone the repo. 16 | 17 | 2. cd command to the current folder. 18 | 19 | 3. Modify the required .env variables. 20 | ``` 21 | VITE_CODE_GEN_URL = '' 22 | ``` 23 | 4. Execute `npm install` to install the corresponding dependencies. 24 | 25 | 5. Execute `npm run dev` in both environments 26 | -------------------------------------------------------------------------------- /CodeGen/ui/react/env.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # Copyright (C) 2024 Intel Corporation 3 | # SPDX-License-Identifier: Apache-2.0 4 | 5 | for i in $(env | grep APP_) #// Make sure to use the prefix APP_ if you have any other prefix in env.production file variable name replace it with APP_ 6 | do 7 | key=$(echo $i | cut -d '=' -f 1) 8 | value=$(echo $i | cut -d '=' -f 2-) 9 | echo $key=$value 10 | 11 | # sed JS and CSS only 12 | find /usr/share/nginx/html -type f \( -name '*.js' -o -name '*.css' \) -exec sed -i "s|${key}|${value}|g" '{}' + 13 | done 14 | -------------------------------------------------------------------------------- /CodeGen/ui/react/index.html: -------------------------------------------------------------------------------- 1 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | Conversations UI 13 | 14 | 15 |
16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /CodeGen/ui/react/nginx.conf: -------------------------------------------------------------------------------- 1 | server { 2 | listen 80; 3 | 4 | gzip on; 5 | gzip_proxied any; 6 | gzip_comp_level 6; 7 | gzip_buffers 16 8k; 8 | gzip_http_version 1.1; 9 | gzip_types font/woff2 text/css application/javascript application/json application/font-woff application/font-tff image/gif image/png image/svg+xml application/octet-stream; 10 | 11 | location / { 12 | root /usr/share/nginx/html; 13 | index index.html index.htm; 14 | try_files $uri $uri/ /index.html =404; 15 | 16 | location ~* \.(gif|jpe?g|png|webp|ico|svg|css|js|mp4|woff2)$ { 17 | expires 1d; 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /CodeGen/ui/react/postcss.config.cjs: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | plugins: { 3 | "postcss-preset-mantine": {}, 4 | "postcss-simple-vars": { 5 | variables: { 6 | "mantine-breakpoint-xs": "36em", 7 | "mantine-breakpoint-sm": "48em", 8 | "mantine-breakpoint-md": "62em", 9 | "mantine-breakpoint-lg": "75em", 10 | "mantine-breakpoint-xl": "88em", 11 | }, 12 | }, 13 | }, 14 | }; 15 | -------------------------------------------------------------------------------- /CodeGen/ui/react/src/__tests__/util.test.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import { describe, expect, test } from "vitest"; 5 | import { getCurrentTimeStamp, uuidv4 } from "../common/util"; 6 | 7 | describe("unit tests", () => { 8 | test("check UUID is of length 36", () => { 9 | expect(uuidv4()).toHaveLength(36); 10 | }); 11 | test("check TimeStamp generated is of unix", () => { 12 | expect(getCurrentTimeStamp()).toBe(Math.floor(Date.now() / 1000)); 13 | }); 14 | }); 15 | -------------------------------------------------------------------------------- /CodeGen/ui/react/src/common/client.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import axios from "axios"; 5 | 6 | //add iterceptors to add any request headers 7 | 8 | export default axios; 9 | -------------------------------------------------------------------------------- /CodeGen/ui/react/src/common/util.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | export const getCurrentTimeStamp = () => { 5 | return Math.floor(Date.now() / 1000); 6 | }; 7 | 8 | export const uuidv4 = () => { 9 | return "10000000-1000-4000-8000-100000000000".replace(/[018]/g, (c) => 10 | (+c ^ (crypto.getRandomValues(new Uint8Array(1))[0] & (15 >> (+c / 4)))).toString(16), 11 | ); 12 | }; 13 | -------------------------------------------------------------------------------- /CodeGen/ui/react/src/components/Message/conversationMessage.module.scss: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | @import "../../styles/styles"; 5 | 6 | .conversationMessage { 7 | @include flex(column, nowrap, flex-start, flex-start); 8 | margin-top: 16px; 9 | padding: 0 32px; 10 | width: 100%; 11 | 12 | & > * { 13 | width: 100%; 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /CodeGen/ui/react/src/components/Shared/CodeRender/codeRender.module.scss: -------------------------------------------------------------------------------- 1 | @import "../../../styles/styles"; 2 | 3 | .code { 4 | margin: 7px 0px; 5 | .codeHead { 6 | background: #379af1; 7 | 8 | padding: 0px 10px !important; 9 | @include flex(row, nowrap, center, space-between); 10 | .codeTitle { 11 | } 12 | .codeActionGroup { 13 | @include flex(row, nowrap, center, flex-start); 14 | } 15 | } 16 | .codeHighlighterDiv { 17 | margin: 0px !important; 18 | } 19 | } 20 | 21 | .inlineCode { 22 | background: #d7d7d7; 23 | } 24 | -------------------------------------------------------------------------------- /CodeGen/ui/react/src/components/Shared/Markdown/markdown.module.scss: -------------------------------------------------------------------------------- 1 | .tableDiv { 2 | table, 3 | th, 4 | td { 5 | border: 1px solid black; 6 | border-collapse: collapse; 7 | } 8 | } 9 | 10 | .md { 11 | li { 12 | margin-left: 35px; /* Adjust the value based on your preference */ 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /CodeGen/ui/react/src/config.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | export const CODE_GEN_URL = import.meta.env.VITE_CODE_GEN_URL; 5 | -------------------------------------------------------------------------------- /CodeGen/ui/react/src/index.scss: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | @import "@mantine/core/styles.css"; 5 | 6 | :root { 7 | font-family: Inter, system-ui, Avenir, Helvetica, Arial, sans-serif; 8 | line-height: 1.5; 9 | font-weight: 400; 10 | } 11 | 12 | html, 13 | body { 14 | position: absolute; 15 | top: 0; 16 | left: 0; 17 | width: 100%; 18 | height: 100%; 19 | overflow: hidden; 20 | } 21 | -------------------------------------------------------------------------------- /CodeGen/ui/react/src/main.tsx: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import React from "react" 5 | import ReactDOM from "react-dom/client" 6 | import App from "./App.tsx" 7 | import "./index.scss" 8 | 9 | ReactDOM.createRoot(document.getElementById("root")!).render( 10 | 11 | 12 | 13 | ) 14 | -------------------------------------------------------------------------------- /CodeGen/ui/react/src/styles/components/_context.scss: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeGen/ui/react/src/styles/components/_context.scss -------------------------------------------------------------------------------- /CodeGen/ui/react/src/styles/components/_sidebar.scss: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | @import "../layout/flex"; 5 | 6 | @mixin sidebar { 7 | @include flex(column, nowrap, flex-start, flex-start); 8 | } 9 | -------------------------------------------------------------------------------- /CodeGen/ui/react/src/styles/components/content.scss: -------------------------------------------------------------------------------- 1 | @mixin textWrapEllipsis { 2 | text-overflow: ellipsis; 3 | white-space: nowrap; 4 | overflow: hidden; 5 | } 6 | -------------------------------------------------------------------------------- /CodeGen/ui/react/src/styles/layout/_basics.scss: -------------------------------------------------------------------------------- 1 | @mixin absolutes { 2 | position: absolute; 3 | top: 0; 4 | left: 0; 5 | width: 100%; 6 | height: 100%; 7 | } 8 | -------------------------------------------------------------------------------- /CodeGen/ui/react/src/styles/layout/_flex.scss: -------------------------------------------------------------------------------- 1 | @mixin flex($direction: row, $wrap: nowrap, $alignItems: center, $justifyContent: center) { 2 | display: flex; 3 | flex-flow: $direction $wrap; 4 | align-items: $alignItems; 5 | justify-content: $justifyContent; 6 | } 7 | -------------------------------------------------------------------------------- /CodeGen/ui/react/src/styles/styles.scss: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | @import "layout/flex"; 5 | @import "layout/basics"; 6 | -------------------------------------------------------------------------------- /CodeGen/ui/react/src/vite-env.d.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | /// 5 | -------------------------------------------------------------------------------- /CodeGen/ui/react/tsconfig.node.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "composite": true, 4 | "skipLibCheck": true, 5 | "module": "ESNext", 6 | "moduleResolution": "bundler", 7 | "allowSyntheticDefaultImports": true, 8 | "strict": true 9 | }, 10 | "include": ["vite.config.ts"] 11 | } 12 | -------------------------------------------------------------------------------- /CodeGen/ui/react/vite.config.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import { defineConfig } from "vitest/config"; 5 | import react from "@vitejs/plugin-react"; 6 | 7 | // https://vitejs.dev/config/ 8 | export default defineConfig({ 9 | css: { 10 | preprocessorOptions: { 11 | scss: { 12 | additionalData: `@import "./src/styles/styles.scss";`, 13 | }, 14 | }, 15 | }, 16 | plugins: [react()], 17 | server: { 18 | port: 3000, 19 | }, 20 | test: { 21 | globals: true, 22 | environment: "jsdom", 23 | }, 24 | define: { 25 | "import.meta.env": process.env, 26 | }, 27 | }); 28 | -------------------------------------------------------------------------------- /CodeGen/ui/svelte/.editorconfig: -------------------------------------------------------------------------------- 1 | [*] 2 | indent_style = tab 3 | 4 | [package.json] 5 | indent_style = space 6 | indent_size = 2 7 | 8 | [*.md] 9 | indent_style = space 10 | indent_size = 2 11 | -------------------------------------------------------------------------------- /CodeGen/ui/svelte/.env: -------------------------------------------------------------------------------- 1 | BASIC_URL = 'http://backend_address:7778/v1/codegen' 2 | -------------------------------------------------------------------------------- /CodeGen/ui/svelte/.eslintignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules 3 | /build 4 | /.svelte-kit 5 | /package 6 | .env 7 | .env.* 8 | !.env.example 9 | 10 | # Ignore files for PNPM, NPM and YARN 11 | pnpm-lock.yaml 12 | package-lock.json 13 | yarn.lock 14 | -------------------------------------------------------------------------------- /CodeGen/ui/svelte/.npmrc: -------------------------------------------------------------------------------- 1 | engine-strict=true 2 | -------------------------------------------------------------------------------- /CodeGen/ui/svelte/.prettierignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules 3 | /build 4 | /.svelte-kit 5 | /package 6 | .env 7 | .env.* 8 | !.env.example 9 | 10 | # Ignore files for PNPM, NPM and YARN 11 | pnpm-lock.yaml 12 | package-lock.json 13 | yarn.lock 14 | -------------------------------------------------------------------------------- /CodeGen/ui/svelte/.prettierrc: -------------------------------------------------------------------------------- 1 | { 2 | "pluginSearchDirs": [ 3 | "." 4 | ], 5 | "overrides": [ 6 | { 7 | "files": "*.svelte", 8 | "options": { 9 | "parser": "svelte" 10 | } 11 | } 12 | ] 13 | } 14 | -------------------------------------------------------------------------------- /CodeGen/ui/svelte/README.md: -------------------------------------------------------------------------------- 1 | # Code Gen 2 | 3 | ## 📸 Project Screenshots 4 | 5 | ![project-screenshot](../../assets/img/codeGen_ui_init.jpg) 6 | 7 | ## 🧐 Features 8 | 9 | Here're some of the project's features: 10 | 11 | - Generate code: generate the corresponding code based on the current user's input. 12 | 13 | ## 🛠️ Get it Running 14 | 15 | 1. Clone the repo. 16 | 17 | 2. cd command to the current folder. 18 | 19 | 3. Modify the required .env variables. 20 | ``` 21 | BASIC_URL = '' 22 | ``` 23 | 4. Execute `npm install` to install the corresponding dependencies. 24 | 25 | 5. Execute `npm run dev` in both environments 26 | -------------------------------------------------------------------------------- /CodeGen/ui/svelte/src/app.pcss: -------------------------------------------------------------------------------- 1 | /* Write your global styles here, in PostCSS syntax */ 2 | @tailwind base; 3 | @tailwind components; 4 | @tailwind utilities; 5 | -------------------------------------------------------------------------------- /CodeGen/ui/svelte/src/lib/assets/imgLogo.svelte: -------------------------------------------------------------------------------- 1 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /CodeGen/ui/svelte/src/lib/index.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Reexport your entry components here 5 | -------------------------------------------------------------------------------- /CodeGen/ui/svelte/src/lib/shared/Store.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import { writable } from "svelte/store"; 5 | 6 | export let kb_id = writable(""); 7 | 8 | export let loading = writable(false); 9 | -------------------------------------------------------------------------------- /CodeGen/ui/svelte/src/lib/shared/Utils.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | export function scrollToBottom(scrollToDiv: HTMLElement) { 5 | if (scrollToDiv) { 6 | setTimeout( 7 | () => 8 | scrollToDiv.scroll({ 9 | behavior: "auto", 10 | top: scrollToDiv.scrollHeight, 11 | }), 12 | 100, 13 | ); 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /CodeGen/ui/svelte/src/routes/+page.ts: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2024 Intel Corporation 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"); 4 | // you may not use this file except in compliance with the License. 5 | // You may obtain a copy of the License at 6 | // 7 | // http://www.apache.org/licenses/LICENSE-2.0 8 | // 9 | // Unless required by applicable law or agreed to in writing, software 10 | // distributed under the License is distributed on an "AS IS" BASIS, 11 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 | // See the License for the specific language governing permissions and 13 | // limitations under the License. 14 | -------------------------------------------------------------------------------- /CodeGen/ui/svelte/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeGen/ui/svelte/static/favicon.png -------------------------------------------------------------------------------- /CodeGen/ui/svelte/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./.svelte-kit/tsconfig.json", 3 | "compilerOptions": { 4 | "allowJs": true, 5 | "checkJs": true, 6 | "esModuleInterop": true, 7 | "forceConsistentCasingInFileNames": true, 8 | "resolveJsonModule": true, 9 | "skipLibCheck": true, 10 | "sourceMap": true, 11 | "strict": true 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /CodeTrans/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | ARG IMAGE_REPO=opea 5 | ARG BASE_TAG=latest 6 | FROM $IMAGE_REPO/comps-base:$BASE_TAG 7 | 8 | COPY ./code_translation.py $HOME/code_translation.py 9 | 10 | ENTRYPOINT ["python", "code_translation.py"] 11 | -------------------------------------------------------------------------------- /CodeTrans/assets/img/codeTrans_ui_init.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeTrans/assets/img/codeTrans_ui_init.png -------------------------------------------------------------------------------- /CodeTrans/assets/img/codeTrans_ui_response.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeTrans/assets/img/codeTrans_ui_response.png -------------------------------------------------------------------------------- /CodeTrans/assets/img/codeTrans_ui_select.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeTrans/assets/img/codeTrans_ui_select.png -------------------------------------------------------------------------------- /CodeTrans/assets/img/code_trans_architecture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeTrans/assets/img/code_trans_architecture.png -------------------------------------------------------------------------------- /CodeTrans/assets/img/example_dashboards.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeTrans/assets/img/example_dashboards.png -------------------------------------------------------------------------------- /CodeTrans/assets/img/tgi_dashboard.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeTrans/assets/img/tgi_dashboard.png -------------------------------------------------------------------------------- /CodeTrans/assets/img/ui-result-page.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeTrans/assets/img/ui-result-page.png -------------------------------------------------------------------------------- /CodeTrans/assets/img/ui-starting-page.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeTrans/assets/img/ui-starting-page.png -------------------------------------------------------------------------------- /CodeTrans/kubernetes/helm/cpu-tgi-values.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | tgi: 5 | enabled: true 6 | vllm: 7 | enabled: false 8 | llm-uservice: 9 | TEXTGEN_BACKEND: TGI 10 | -------------------------------------------------------------------------------- /CodeTrans/kubernetes/helm/cpu-values.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | tgi: 5 | enabled: false 6 | vllm: 7 | enabled: true 8 | llm-uservice: 9 | TEXTGEN_BACKEND: vLLM 10 | -------------------------------------------------------------------------------- /CodeTrans/ui/svelte/.env: -------------------------------------------------------------------------------- 1 | BASE_URL = '/v1/codetrans' 2 | 3 | 4 | -------------------------------------------------------------------------------- /CodeTrans/ui/svelte/.gitignore: -------------------------------------------------------------------------------- 1 | */node_modules 2 | /build 3 | /dist 4 | */.svelte-kit 5 | 6 | -------------------------------------------------------------------------------- /CodeTrans/ui/svelte/.npmrc: -------------------------------------------------------------------------------- 1 | engine-strict=true 2 | -------------------------------------------------------------------------------- /CodeTrans/ui/svelte/src/app.pcss: -------------------------------------------------------------------------------- 1 | /* Write your global styles here, in PostCSS syntax */ 2 | @tailwind base; 3 | @tailwind components; 4 | @tailwind utilities; 5 | -------------------------------------------------------------------------------- /CodeTrans/ui/svelte/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/CodeTrans/ui/svelte/static/favicon.png -------------------------------------------------------------------------------- /CodeTrans/ui/svelte/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./.svelte-kit/tsconfig.json", 3 | "compilerOptions": { 4 | "allowJs": true, 5 | "checkJs": true, 6 | "esModuleInterop": true, 7 | "forceConsistentCasingInFileNames": true, 8 | "resolveJsonModule": true, 9 | "skipLibCheck": true, 10 | "sourceMap": true, 11 | "strict": true, 12 | "module": "NodeNext", 13 | "moduleResolution": "NodeNext" 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /DBQnA/assets/img/dbQnA_ui_db_credentials.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/DBQnA/assets/img/dbQnA_ui_db_credentials.png -------------------------------------------------------------------------------- /DBQnA/assets/img/dbQnA_ui_enter_question.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/DBQnA/assets/img/dbQnA_ui_enter_question.png -------------------------------------------------------------------------------- /DBQnA/assets/img/dbQnA_ui_failed_db_connection.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/DBQnA/assets/img/dbQnA_ui_failed_db_connection.png -------------------------------------------------------------------------------- /DBQnA/assets/img/dbQnA_ui_failed_sql_output_generation.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/DBQnA/assets/img/dbQnA_ui_failed_sql_output_generation.png -------------------------------------------------------------------------------- /DBQnA/assets/img/dbQnA_ui_init.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/DBQnA/assets/img/dbQnA_ui_init.png -------------------------------------------------------------------------------- /DBQnA/assets/img/dbQnA_ui_succesful_sql_output_generation.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/DBQnA/assets/img/dbQnA_ui_succesful_sql_output_generation.png -------------------------------------------------------------------------------- /DBQnA/assets/img/dbQnA_ui_successful_db_connection.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/DBQnA/assets/img/dbQnA_ui_successful_db_connection.png -------------------------------------------------------------------------------- /DBQnA/tests/README.md: -------------------------------------------------------------------------------- 1 | # DBQnA E2E test scripts 2 | 3 | ## Set the required environment variable 4 | 5 | ```bash 6 | export HF_TOKEN="Your_Huggingface_API_Token" 7 | ``` 8 | 9 | ## Run test 10 | 11 | On Intel Xeon with TGI: 12 | 13 | ```bash 14 | bash test_compose_on_xeon.sh 15 | ``` 16 | 17 | On AMD ROCm with TGI: 18 | 19 | ```bash 20 | bash test_compose_on_rocm.sh 21 | ``` 22 | -------------------------------------------------------------------------------- /DBQnA/ui/react/.env: -------------------------------------------------------------------------------- 1 | VITE_TEXT_TO_SQL_URL=${TEXT_TO_SQL_URL} 2 | -------------------------------------------------------------------------------- /DBQnA/ui/react/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | # misc 15 | .DS_Store 16 | .env.local 17 | .env.development.local 18 | .env.test.local 19 | .env.production.local 20 | 21 | npm-debug.log* 22 | yarn-debug.log* 23 | yarn-error.log* 24 | -------------------------------------------------------------------------------- /DBQnA/ui/react/index.html: -------------------------------------------------------------------------------- 1 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | Opea DBQnA 13 | 14 | 15 |
16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /DBQnA/ui/react/nginx.conf: -------------------------------------------------------------------------------- 1 | server { 2 | listen 80; 3 | 4 | gzip on; 5 | gzip_proxied any; 6 | gzip_comp_level 6; 7 | gzip_buffers 16 8k; 8 | gzip_http_version 1.1; 9 | gzip_types font/woff2 text/css application/javascript application/json application/font-woff application/font-tff image/gif image/png image/svg+xml application/octet-stream; 10 | 11 | location / { 12 | root /usr/share/nginx/html; 13 | index index.html index.htm; 14 | try_files $uri $uri/ /index.html =404; 15 | 16 | location ~* \.(gif|jpe?g|png|webp|ico|svg|css|js|mp4|woff2)$ { 17 | expires 1d; 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /DBQnA/ui/react/postcss.config.cjs: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | plugins: { 3 | "postcss-preset-mantine": {}, 4 | "postcss-simple-vars": { 5 | variables: { 6 | "mantine-breakpoint-xs": "36em", 7 | "mantine-breakpoint-sm": "48em", 8 | "mantine-breakpoint-md": "62em", 9 | "mantine-breakpoint-lg": "75em", 10 | "mantine-breakpoint-xl": "88em", 11 | }, 12 | }, 13 | }, 14 | }; 15 | -------------------------------------------------------------------------------- /DBQnA/ui/react/src/config.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | export const TEXT_TO_SQL_URL = import.meta.env.VITE_TEXT_TO_SQL_URL; 5 | -------------------------------------------------------------------------------- /DBQnA/ui/react/src/index.scss: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | @import "@mantine/core/styles.css"; 5 | 6 | :root { 7 | font-family: Inter, system-ui, Avenir, Helvetica, Arial, sans-serif; 8 | line-height: 1.5; 9 | font-weight: 400; 10 | } 11 | 12 | html, 13 | body { 14 | position: absolute; 15 | top: 0; 16 | left: 0; 17 | width: 100%; 18 | height: 100%; 19 | overflow: hidden; 20 | } 21 | -------------------------------------------------------------------------------- /DBQnA/ui/react/src/index.tsx: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import ReactDOM from 'react-dom/client'; 3 | import './index.css'; 4 | import App from './App'; 5 | // import reportWebVitals from './reportWebVitals'; 6 | 7 | const root = ReactDOM.createRoot( 8 | document.getElementById('root') as HTMLElement 9 | ); 10 | root.render( 11 | 12 | 13 | 14 | ); 15 | 16 | // If you want to start measuring performance in your app, pass a function 17 | // to log results (for example: reportWebVitals(console.log)) 18 | // or send to an analytics endpoint. Learn more: https://bit.ly/CRA-vitals 19 | // reportWebVitals(); 20 | -------------------------------------------------------------------------------- /DBQnA/ui/react/src/main.tsx: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import React from "react" 5 | import ReactDOM from "react-dom/client" 6 | import App from './App'; 7 | import "./index.scss" 8 | 9 | ReactDOM.createRoot(document.getElementById("root")!).render( 10 | 11 | 12 | 13 | ) 14 | -------------------------------------------------------------------------------- /DBQnA/ui/react/src/styles/layout/_basics.scss: -------------------------------------------------------------------------------- 1 | @mixin absolutes { 2 | position: absolute; 3 | top: 0; 4 | left: 0; 5 | width: 100%; 6 | height: 100%; 7 | } 8 | -------------------------------------------------------------------------------- /DBQnA/ui/react/src/styles/layout/_flex.scss: -------------------------------------------------------------------------------- 1 | @mixin flex($direction: row, $wrap: nowrap, $alignItems: center, $justifyContent: center) { 2 | display: flex; 3 | flex-flow: $direction $wrap; 4 | align-items: $alignItems; 5 | justify-content: $justifyContent; 6 | } 7 | -------------------------------------------------------------------------------- /DBQnA/ui/react/src/styles/styles.scss: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | @import "layout/flex"; 5 | @import "layout/basics"; 6 | -------------------------------------------------------------------------------- /DBQnA/ui/react/src/vite-env.d.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | /// 5 | -------------------------------------------------------------------------------- /DBQnA/ui/react/tsconfig.node.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "composite": true, 4 | "skipLibCheck": true, 5 | "module": "ESNext", 6 | "moduleResolution": "bundler", 7 | "allowSyntheticDefaultImports": true, 8 | "strict": true 9 | }, 10 | "include": ["vite.config.ts"] 11 | } 12 | -------------------------------------------------------------------------------- /DocIndexRetriever/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | ARG IMAGE_REPO=opea 5 | ARG BASE_TAG=latest 6 | FROM $IMAGE_REPO/comps-base:$BASE_TAG 7 | 8 | COPY ./retrieval_tool.py $HOME/retrieval_tool.py 9 | 10 | ENTRYPOINT ["python", "retrieval_tool.py"] 11 | -------------------------------------------------------------------------------- /DocIndexRetriever/tests/README.md: -------------------------------------------------------------------------------- 1 | # DocIndexRetriever E2E test scripts 2 | 3 | ## Set the required environment variable 4 | 5 | ```bash 6 | export HF_TOKEN="Your_Huggingface_API_Token" 7 | ``` 8 | 9 | ## Run test 10 | 11 | On Intel Xeon with TGI: 12 | 13 | ```bash 14 | bash test_compose_on_xeon.sh 15 | ``` 16 | 17 | On Intel Gaudi with TGI: 18 | 19 | ```bash 20 | bash test_compose_on_gaudi.sh 21 | ``` 22 | 23 | On AMD ROCm with TGI: 24 | 25 | ```bash 26 | bash test_compose_on_rocm.sh 27 | ``` 28 | 29 | On AMD ROCm with vLLM: 30 | 31 | ```bash 32 | bash test_compose_vllm_on_rocm.sh 33 | ``` 34 | -------------------------------------------------------------------------------- /DocSum/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | ARG IMAGE_REPO=opea 5 | ARG BASE_TAG=latest 6 | FROM $IMAGE_REPO/comps-base:$BASE_TAG 7 | 8 | USER root 9 | # FFmpeg needed for media processing 10 | RUN apt-get update && \ 11 | apt-get install -y --no-install-recommends ffmpeg && \ 12 | apt-get clean && rm -rf /var/lib/apt/lists/* 13 | USER user 14 | 15 | COPY ./docsum.py $HOME/docsum.py 16 | 17 | ENTRYPOINT ["python", "docsum.py"] 18 | -------------------------------------------------------------------------------- /DocSum/assets/img/docSum_ui_exchange.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/DocSum/assets/img/docSum_ui_exchange.png -------------------------------------------------------------------------------- /DocSum/assets/img/docSum_ui_gradio_text.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/DocSum/assets/img/docSum_ui_gradio_text.png -------------------------------------------------------------------------------- /DocSum/assets/img/docSum_ui_response.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/DocSum/assets/img/docSum_ui_response.png -------------------------------------------------------------------------------- /DocSum/assets/img/docSum_ui_text.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/DocSum/assets/img/docSum_ui_text.png -------------------------------------------------------------------------------- /DocSum/assets/img/docSum_ui_upload.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/DocSum/assets/img/docSum_ui_upload.png -------------------------------------------------------------------------------- /DocSum/assets/img/docsum-ui-react-error.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/DocSum/assets/img/docsum-ui-react-error.png -------------------------------------------------------------------------------- /DocSum/assets/img/docsum-ui-react-file.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/DocSum/assets/img/docsum-ui-react-file.png -------------------------------------------------------------------------------- /DocSum/assets/img/docsum-ui-react.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/DocSum/assets/img/docsum-ui-react.png -------------------------------------------------------------------------------- /DocSum/assets/img/docsum_architecture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/DocSum/assets/img/docsum_architecture.png -------------------------------------------------------------------------------- /DocSum/assets/img/docsum_workflow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/DocSum/assets/img/docsum_workflow.png -------------------------------------------------------------------------------- /DocSum/assets/img/ui-result-page.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/DocSum/assets/img/ui-result-page.png -------------------------------------------------------------------------------- /DocSum/assets/img/ui-starting-page.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/DocSum/assets/img/ui-starting-page.png -------------------------------------------------------------------------------- /DocSum/kubernetes/helm/cpu-tgi-values.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2025 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | llm-uservice: 5 | DOCSUM_BACKEND: "TGI" 6 | tgi: 7 | enabled: true 8 | vllm: 9 | enabled: false 10 | -------------------------------------------------------------------------------- /DocSum/kubernetes/helm/cpu-values.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2025 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | llm-uservice: 5 | DOCSUM_BACKEND: "vLLM" 6 | tgi: 7 | enabled: false 8 | vllm: 9 | enabled: true 10 | -------------------------------------------------------------------------------- /DocSum/tests/data/short.txt: -------------------------------------------------------------------------------- 1 | Text Embeddings Inference (TEI) is a toolkit for deploying and serving open source text embeddings and sequence classification models. TEI enables high-performance extraction for the most popular models, including FlagEmbedding, Ember, GTE and E5. 2 | -------------------------------------------------------------------------------- /DocSum/tests/data/test.mp4: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/DocSum/tests/data/test.mp4 -------------------------------------------------------------------------------- /DocSum/tests/data/test.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/DocSum/tests/data/test.wav -------------------------------------------------------------------------------- /DocSum/ui/docker/Dockerfile.react: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | # Use node 20.11.1 as the base image 5 | FROM node:20.11.1 as vite-app 6 | 7 | COPY . /usr/app 8 | WORKDIR /usr/app/react 9 | 10 | ARG BACKEND_SERVICE_ENDPOINT 11 | ENV VITE_DOC_SUM_URL=$BACKEND_SERVICE_ENDPOINT 12 | 13 | RUN ["npm", "install"] 14 | RUN ["npm", "run", "build"] 15 | 16 | 17 | FROM nginx:alpine 18 | EXPOSE 80 19 | 20 | 21 | COPY --from=vite-app /usr/app/react/nginx.conf /etc/nginx/conf.d/default.conf 22 | COPY --from=vite-app /usr/app/react/dist /usr/share/nginx/html 23 | 24 | ENTRYPOINT ["nginx", "-g", "daemon off;"] 25 | -------------------------------------------------------------------------------- /DocSum/ui/gradio/requirements.txt: -------------------------------------------------------------------------------- 1 | docx2txt 2 | gradio==5.11.0 3 | langchain_community 4 | moviepy==1.0.3 5 | numpy==1.26.4 6 | opencv-python==4.10.0.82 7 | Pillow==10.3.0 8 | pypdf 9 | unstructured 10 | -------------------------------------------------------------------------------- /DocSum/ui/react/.env: -------------------------------------------------------------------------------- 1 | VITE_DOC_SUM_URL=http://backend_address:8888/v1/docsum 2 | -------------------------------------------------------------------------------- /DocSum/ui/react/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | root: true, 3 | env: { browser: true, es2020: true }, 4 | extends: ["eslint:recommended", "plugin:@typescript-eslint/recommended", "plugin:react-hooks/recommended"], 5 | ignorePatterns: ["dist", ".eslintrc.cjs"], 6 | parser: "@typescript-eslint/parser", 7 | plugins: ["react-refresh"], 8 | rules: { 9 | "react-refresh/only-export-components": ["warn", { allowConstantExport: true }], 10 | }, 11 | }; 12 | -------------------------------------------------------------------------------- /DocSum/ui/react/.gitignore: -------------------------------------------------------------------------------- 1 | # Logs 2 | logs 3 | *.log 4 | npm-debug.log* 5 | yarn-debug.log* 6 | yarn-error.log* 7 | pnpm-debug.log* 8 | lerna-debug.log* 9 | 10 | node_modules 11 | dist 12 | dist-ssr 13 | *.local 14 | 15 | # Editor directories and files 16 | .vscode/* 17 | !.vscode/extensions.json 18 | .idea 19 | .DS_Store 20 | *.suo 21 | *.ntvs* 22 | *.njsproj 23 | *.sln 24 | *.sw? 25 | -------------------------------------------------------------------------------- /DocSum/ui/react/index.html: -------------------------------------------------------------------------------- 1 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | Opea Doc Sum 13 | 14 | 15 |
16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /DocSum/ui/react/nginx.conf: -------------------------------------------------------------------------------- 1 | server { 2 | listen 80; 3 | 4 | gzip on; 5 | gzip_proxied any; 6 | gzip_comp_level 6; 7 | gzip_buffers 16 8k; 8 | gzip_http_version 1.1; 9 | gzip_types font/woff2 text/css application/javascript application/json application/font-woff application/font-tff image/gif image/png image/svg+xml application/octet-stream; 10 | 11 | location / { 12 | root /usr/share/nginx/html; 13 | index index.html index.htm; 14 | try_files $uri $uri/ /index.html =404; 15 | 16 | location ~* \.(gif|jpe?g|png|webp|ico|svg|css|js|mp4|woff2)$ { 17 | expires 1d; 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /DocSum/ui/react/postcss.config.cjs: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | plugins: { 3 | "postcss-preset-mantine": {}, 4 | "postcss-simple-vars": { 5 | variables: { 6 | "mantine-breakpoint-xs": "36em", 7 | "mantine-breakpoint-sm": "48em", 8 | "mantine-breakpoint-md": "62em", 9 | "mantine-breakpoint-lg": "75em", 10 | "mantine-breakpoint-xl": "88em", 11 | }, 12 | }, 13 | }, 14 | }; 15 | -------------------------------------------------------------------------------- /DocSum/ui/react/src/__tests__/util.test.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import { describe, expect, test } from "vitest"; 5 | import { getCurrentTimeStamp, uuidv4 } from "../common/util"; 6 | 7 | describe("unit tests", () => { 8 | test("check UUID is of length 36", () => { 9 | expect(uuidv4()).toHaveLength(36); 10 | }); 11 | test("check TimeStamp generated is of unix", () => { 12 | expect(getCurrentTimeStamp()).toBe(Math.floor(Date.now() / 1000)); 13 | }); 14 | }); 15 | -------------------------------------------------------------------------------- /DocSum/ui/react/src/common/client.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import axios from "axios"; 5 | 6 | //add iterceptors to add any request headers 7 | 8 | export default axios; 9 | -------------------------------------------------------------------------------- /DocSum/ui/react/src/common/util.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | export const getCurrentTimeStamp = () => { 5 | return Math.floor(Date.now() / 1000); 6 | }; 7 | 8 | export const uuidv4 = () => { 9 | return "10000000-1000-4000-8000-100000000000".replace(/[018]/g, (c) => 10 | (+c ^ (crypto.getRandomValues(new Uint8Array(1))[0] & (15 >> (+c / 4)))).toString(16), 11 | ); 12 | }; 13 | -------------------------------------------------------------------------------- /DocSum/ui/react/src/components/Shared/CodeRender/codeRender.module.scss: -------------------------------------------------------------------------------- 1 | @import "../../../styles/styles"; 2 | 3 | .code { 4 | margin: 7px 0px; 5 | .codeHead { 6 | background: #379af1; 7 | 8 | padding: 0px 10px !important; 9 | @include flex(row, nowrap, center, space-between); 10 | .codeTitle { 11 | } 12 | .codeActionGroup { 13 | @include flex(row, nowrap, center, flex-start); 14 | } 15 | } 16 | .codeHighlighterDiv { 17 | margin: 0px !important; 18 | } 19 | } 20 | 21 | .inlineCode { 22 | background: #d7d7d7; 23 | } 24 | -------------------------------------------------------------------------------- /DocSum/ui/react/src/components/Shared/Markdown/markdown.module.scss: -------------------------------------------------------------------------------- 1 | .tableDiv { 2 | table, 3 | th, 4 | td { 5 | border: 1px solid black; 6 | border-collapse: collapse; 7 | } 8 | } 9 | 10 | .md { 11 | li { 12 | margin-left: 35px; /* Adjust the value based on your preference */ 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /DocSum/ui/react/src/config.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | export const DOC_SUM_URL = import.meta.env.VITE_DOC_SUM_URL; 5 | -------------------------------------------------------------------------------- /DocSum/ui/react/src/index.scss: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | @import "@mantine/core/styles.css"; 5 | 6 | :root { 7 | font-family: Inter, system-ui, Avenir, Helvetica, Arial, sans-serif; 8 | line-height: 1.5; 9 | font-weight: 400; 10 | } 11 | 12 | html, 13 | body { 14 | position: absolute; 15 | top: 0; 16 | left: 0; 17 | width: 100%; 18 | height: 100%; 19 | overflow: hidden; 20 | } 21 | -------------------------------------------------------------------------------- /DocSum/ui/react/src/main.tsx: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import React from "react" 5 | import ReactDOM from "react-dom/client" 6 | import App from "./App.tsx" 7 | import "./index.scss" 8 | 9 | ReactDOM.createRoot(document.getElementById("root")!).render( 10 | 11 | 12 | 13 | ) 14 | -------------------------------------------------------------------------------- /DocSum/ui/react/src/styles/components/_sidebar.scss: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | @import "../layout/flex"; 5 | 6 | @mixin sidebar { 7 | @include flex(column, nowrap, flex-start, flex-start); 8 | } 9 | -------------------------------------------------------------------------------- /DocSum/ui/react/src/styles/components/content.scss: -------------------------------------------------------------------------------- 1 | @mixin textWrapEllipsis { 2 | text-overflow: ellipsis; 3 | white-space: nowrap; 4 | overflow: hidden; 5 | } 6 | -------------------------------------------------------------------------------- /DocSum/ui/react/src/styles/layout/_basics.scss: -------------------------------------------------------------------------------- 1 | @mixin absolutes { 2 | position: absolute; 3 | top: 0; 4 | left: 0; 5 | width: 100%; 6 | height: 100%; 7 | } 8 | -------------------------------------------------------------------------------- /DocSum/ui/react/src/styles/layout/_flex.scss: -------------------------------------------------------------------------------- 1 | @mixin flex($direction: row, $wrap: nowrap, $alignItems: center, $justifyContent: center) { 2 | display: flex; 3 | flex-flow: $direction $wrap; 4 | align-items: $alignItems; 5 | justify-content: $justifyContent; 6 | } 7 | -------------------------------------------------------------------------------- /DocSum/ui/react/src/styles/styles.scss: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | @import "layout/flex"; 5 | @import "layout/basics"; 6 | -------------------------------------------------------------------------------- /DocSum/ui/react/src/vite-env.d.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | /// 5 | -------------------------------------------------------------------------------- /DocSum/ui/react/tsconfig.node.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "composite": true, 4 | "skipLibCheck": true, 5 | "module": "ESNext", 6 | "moduleResolution": "bundler", 7 | "allowSyntheticDefaultImports": true, 8 | "strict": true 9 | }, 10 | "include": ["vite.config.ts"] 11 | } 12 | -------------------------------------------------------------------------------- /DocSum/ui/react/vite.config.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import { defineConfig } from "vitest/config"; 5 | import react from "@vitejs/plugin-react"; 6 | 7 | // https://vitejs.dev/config/ 8 | export default defineConfig({ 9 | css: { 10 | preprocessorOptions: { 11 | scss: { 12 | additionalData: `@import "./src/styles/styles.scss";`, 13 | }, 14 | }, 15 | }, 16 | plugins: [react()], 17 | server: { 18 | port: 3000, 19 | }, 20 | test: { 21 | globals: true, 22 | environment: "jsdom", 23 | }, 24 | define: { 25 | "import.meta.env": process.env, 26 | }, 27 | }); 28 | -------------------------------------------------------------------------------- /DocSum/ui/svelte/.env: -------------------------------------------------------------------------------- 1 | DOC_BASE_URL = 'http://backend_address:8888/v1/docsum' 2 | -------------------------------------------------------------------------------- /DocSum/ui/svelte/.gitignore: -------------------------------------------------------------------------------- 1 | */node_modules 2 | /build 3 | /dist 4 | */.svelte-kit 5 | 6 | -------------------------------------------------------------------------------- /DocSum/ui/svelte/.npmrc: -------------------------------------------------------------------------------- 1 | engine-strict=true 2 | -------------------------------------------------------------------------------- /DocSum/ui/svelte/src/app.pcss: -------------------------------------------------------------------------------- 1 | /* Write your global styles here, in PostCSS syntax */ 2 | @tailwind base; 3 | @tailwind components; 4 | @tailwind utilities; 5 | -------------------------------------------------------------------------------- /DocSum/ui/svelte/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/DocSum/ui/svelte/static/favicon.png -------------------------------------------------------------------------------- /DocSum/ui/svelte/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./.svelte-kit/tsconfig.json", 3 | "compilerOptions": { 4 | "allowJs": true, 5 | "checkJs": true, 6 | "esModuleInterop": true, 7 | "forceConsistentCasingInFileNames": true, 8 | "resolveJsonModule": true, 9 | "skipLibCheck": true, 10 | "sourceMap": true, 11 | "strict": true, 12 | "module": "NodeNext", 13 | "moduleResolution": "NodeNext" 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /EdgeCraftRAG/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | ARG IMAGE_REPO=opea 5 | ARG BASE_TAG=latest 6 | FROM $IMAGE_REPO/comps-base:$BASE_TAG 7 | 8 | COPY ./chatqna.py $HOME/chatqna.py 9 | 10 | ENTRYPOINT ["python", "chatqna.py"] -------------------------------------------------------------------------------- /EdgeCraftRAG/assets/img/chat_with_rag.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/EdgeCraftRAG/assets/img/chat_with_rag.png -------------------------------------------------------------------------------- /EdgeCraftRAG/assets/img/create_pipeline.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/EdgeCraftRAG/assets/img/create_pipeline.png -------------------------------------------------------------------------------- /EdgeCraftRAG/assets/img/upload_data.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/EdgeCraftRAG/assets/img/upload_data.png -------------------------------------------------------------------------------- /EdgeCraftRAG/docker_compose/intel/gpu/arc/set_env.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | # Copyright (C) 2024 Intel Corporation 4 | # SPDX-License-Identifier: Apache-2.0 5 | pushd "../../../../../" > /dev/null 6 | source .set_env.sh 7 | popd > /dev/null 8 | 9 | export MODEL_PATH=${MODEL_PATH} 10 | export DOC_PATH=${DOC_PATH} 11 | export UI_TMPFILE_PATH=${UI_TMPFILE_PATH} 12 | export HOST_IP=${HOST_IP} 13 | export LLM_MODEL=${LLM_MODEL} 14 | export HF_ENDPOINT=${HF_ENDPOINT} 15 | export vLLM_ENDPOINT=${vLLM_ENDPOINT} 16 | export HF_TOKEN=${HF_TOKEN} 17 | export no_proxy="localhost, 127.0.0.1, 192.168.1.1" 18 | -------------------------------------------------------------------------------- /EdgeCraftRAG/edgecraftrag/__init__.py: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | -------------------------------------------------------------------------------- /EdgeCraftRAG/edgecraftrag/api/__init__.py: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | -------------------------------------------------------------------------------- /EdgeCraftRAG/edgecraftrag/api/v1/__init__.py: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | -------------------------------------------------------------------------------- /EdgeCraftRAG/edgecraftrag/components/__init__.py: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | -------------------------------------------------------------------------------- /EdgeCraftRAG/edgecraftrag/controllers/__init__.py: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | -------------------------------------------------------------------------------- /EdgeCraftRAG/edgecraftrag/prompt_template/default_prompt.txt: -------------------------------------------------------------------------------- 1 | <|im_start|>System: You are an AI assistant. Your task is to learn from the following context. Then answer the user's question based on what you learned from the context but not your own knowledge.<|im_end|> 2 | 3 | <|im_start|>{context}<|im_end|> 4 | 5 | <|im_start|>System: Pay attention to your formatting of response. If you need to reference content from context, try to keep the formatting.<|im_end|> 6 | <|im_start|>System: Try to summarize from the context, do some reasoning before response, then response. Make sure your response is logically sound and self-consistent.<|im_end|> 7 | 8 | <|im_start|>{input} -------------------------------------------------------------------------------- /EdgeCraftRAG/edgecraftrag/requirements.txt: -------------------------------------------------------------------------------- 1 | docx2txt 2 | EbookLib>=0.18 3 | faiss-cpu>=1.8.0.post1 4 | html2text>=2025.4.15 5 | langchain-core>=0.2.29 6 | llama-index>=0.11.0 7 | llama-index-embeddings-openvino>=0.4.0 8 | llama-index-llms-openai-like>=0.2.0 9 | llama-index-llms-openvino>=0.3.1 10 | llama-index-postprocessor-openvino-rerank>=0.3.0 11 | llama-index-readers-file>=0.4.0 12 | llama-index-retrievers-bm25>=0.3.0 13 | llama-index-vector-stores-faiss>=0.2.1 14 | opea-comps>=1.2 15 | pillow>=10.4.0 16 | py-cpuinfo>=9.0.0 17 | python-docx==1.1.2 18 | unstructured==0.16.11 19 | unstructured[pdf] 20 | -------------------------------------------------------------------------------- /EdgeCraftRAG/tests/README.md: -------------------------------------------------------------------------------- 1 | # EdgeCraftRAG E2E test scripts 2 | 3 | ## Set the required environment variable 4 | 5 | ```bash 6 | export HF_TOKEN="Your_Huggingface_API_Token" 7 | ``` 8 | 9 | ## Run test 10 | 11 | On Intel ARC with TGI: 12 | 13 | ```bash 14 | bash test_compose_on_arc.sh 15 | ``` 16 | 17 | On Intel ARC with vLLM: 18 | 19 | ```bash 20 | bash test_compose_vllm_on_arc.sh 21 | ``` 22 | -------------------------------------------------------------------------------- /EdgeCraftRAG/tests/configs/test_data.json: -------------------------------------------------------------------------------- 1 | { 2 | "text": "A test case for the rag pipeline. The test id is 1234567890. There are several tests in this test case. The first test is for node parser. There are 3 types of node parsers. Their names are Aa, Bb and Cc. The second test is for indexer. The indexer will do the indexing for the given nodes. The last test is for retriever. Retrieving text is based on similarity search." 3 | } 4 | -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/docker/Dockerfile.ui: -------------------------------------------------------------------------------- 1 | FROM node:20.18.1 AS vue-app 2 | 3 | RUN apt-get update -y && apt-get install -y git 4 | 5 | RUN useradd -m -s /bin/bash user && \ 6 | mkdir -p /home/user && \ 7 | chown -R user /home/user/ 8 | 9 | COPY ./ui/vue /home/user/ui 10 | 11 | RUN mkdir -p /home/user/ui 12 | ENV UI_TMPFILE_PATH=/home/user/ui 13 | 14 | WORKDIR /home/user/ui 15 | 16 | RUN npm install 17 | 18 | RUN npm run build 19 | 20 | FROM nginx:stable-alpine 21 | 22 | COPY --from=vue-app home/user/ui/dist /usr/share/nginx/html 23 | 24 | COPY ./ui/vue/nginx.conf /etc/nginx/nginx.conf 25 | 26 | EXPOSE 8082 27 | 28 | CMD ["nginx", "-g", "daemon off;"] 29 | 30 | -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/gradio/__init__.py: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/gradio/assets/ai-logo-inline-ondark-3000.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/EdgeCraftRAG/ui/gradio/assets/ai-logo-inline-ondark-3000.png -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/gradio/assets/ai-logo-inline-onlight-3000.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/EdgeCraftRAG/ui/gradio/assets/ai-logo-inline-onlight-3000.png -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/gradio/requirements.txt: -------------------------------------------------------------------------------- 1 | distro>=1.9.0 2 | gradio>=4.44.1 3 | loguru>=0.7.2 4 | omegaconf>=2.3.0 5 | openvino>=2024.4.0 6 | psutil>=6.1.0 7 | py-cpuinfo>=9.0.0 8 | unstructured==0.16.11 9 | uvicorn>=0.30.6 10 | -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/.env.development: -------------------------------------------------------------------------------- 1 | # Local 2 | ENV = development 3 | 4 | # Local Api 5 | VITE_API_URL = http://10.67.106.236:16010/ 6 | VITE_CHATBOT_URL = http://10.67.106.236:16011/ -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/.env.production: -------------------------------------------------------------------------------- 1 | # Online 2 | ENV = production 3 | 4 | # Online Api 5 | VITE_API_URL = / 6 | VITE_CHATBOT_URL = / -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/.gitignore: -------------------------------------------------------------------------------- 1 | # Logs 2 | logs 3 | *.log 4 | npm-debug.log* 5 | yarn-debug.log* 6 | yarn-error.log* 7 | pnpm-debug.log* 8 | lerna-debug.log* 9 | 10 | node_modules 11 | dist 12 | dist-ssr 13 | *.local 14 | 15 | # Editor directories and files 16 | .vscode/* 17 | !.vscode/extensions.json 18 | .idea 19 | .DS_Store 20 | *.suo 21 | *.ntvs* 22 | *.njsproj 23 | *.sln 24 | *.sw? 25 | -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/EdgeCraftRAG/ui/vue/README.md -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/index.html: -------------------------------------------------------------------------------- 1 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | Edge Craft RAG based Q&A Chatbot 14 | 15 | 16 | 17 |
18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/public/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/EdgeCraftRAG/ui/vue/public/favicon.ico -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/public/favicon1.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/EdgeCraftRAG/ui/vue/public/favicon1.ico -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/src/assets/iconFont/iconfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/EdgeCraftRAG/ui/vue/src/assets/iconFont/iconfont.ttf -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/src/assets/iconFont/iconfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/EdgeCraftRAG/ui/vue/src/assets/iconFont/iconfont.woff -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/src/assets/iconFont/iconfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/EdgeCraftRAG/ui/vue/src/assets/iconFont/iconfont.woff2 -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/src/assets/images/404-bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/EdgeCraftRAG/ui/vue/src/assets/images/404-bg.png -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/src/assets/images/noData.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/EdgeCraftRAG/ui/vue/src/assets/images/noData.png -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/src/enums/antEnum.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2025 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | export enum AntTheme { 5 | Black = "", 6 | } 7 | -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/src/i18n/index.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2025 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import { createI18n } from "vue-i18n"; 5 | import { Local } from "@/utils/storage"; 6 | import enLocale from "ant-design-vue/es/locale/en_US"; 7 | import zhLocale from "ant-design-vue/es/locale/zh_CN"; 8 | import en from "./en"; 9 | import zh from "./zh"; 10 | 11 | const messages = { 12 | "en-US": { ...en, ...enLocale }, 13 | "zh-CN": { ...zh, ...zhLocale }, 14 | }; 15 | 16 | const i18n = createI18n({ 17 | locale: Local.get("lang") || "en-US", 18 | fallbackLocale: "en-US", 19 | messages, 20 | }); 21 | 22 | export default i18n; 23 | -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/src/layout/Main.vue: -------------------------------------------------------------------------------- 1 | 11 | 15 | -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/src/router/index.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2025 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import { createRouter, createWebHashHistory } from "vue-router"; 5 | import { routeList, notFoundAndNoPower } from "./routes"; 6 | 7 | const router = createRouter({ 8 | history: createWebHashHistory(), 9 | routes: [...notFoundAndNoPower, ...routeList], 10 | }); 11 | 12 | export default router; 13 | -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/src/store/index.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2025 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import { createPinia } from "pinia"; 5 | import piniaPluginPersistedstate from "pinia-plugin-persistedstate"; 6 | 7 | const pinia = createPinia(); 8 | pinia.use(piniaPluginPersistedstate); 9 | 10 | export default pinia; 11 | -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/src/store/pipeline.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2025 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import { defineStore } from "pinia"; 5 | 6 | export const pipelineAppStore = defineStore("pipeline", { 7 | state: () => ({ 8 | activatedPipeline: "", 9 | }), 10 | persist: { 11 | key: "pipelineInfo", 12 | storage: localStorage, 13 | }, 14 | actions: { 15 | setPipelineActivate(name: string) { 16 | this.activatedPipeline = name; 17 | }, 18 | }, 19 | }); 20 | -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/src/store/theme.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2025 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import { defineStore } from "pinia"; 5 | 6 | export const themeAppStore = defineStore("theme", { 7 | state: () => ({ 8 | theme: "light", 9 | }), 10 | persist: { 11 | key: "themeInfo", 12 | storage: localStorage, 13 | }, 14 | actions: { 15 | toggleTheme(type: string) { 16 | this.theme = type; 17 | }, 18 | }, 19 | }); 20 | -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/src/store/user.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2025 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import { defineStore } from "pinia"; 5 | 6 | export const userAppStore = defineStore("user", { 7 | state: () => ({ 8 | userGuide: false, 9 | }), 10 | persist: { 11 | key: "userInfo", 12 | storage: localStorage, 13 | }, 14 | actions: { 15 | setUserGuideState(state: boolean) { 16 | this.userGuide = state; 17 | }, 18 | }, 19 | }); 20 | -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/src/theme/index.less: -------------------------------------------------------------------------------- 1 | @import "./variables.less"; 2 | @import "./layout.less"; 3 | @import "./ant.less"; 4 | @import "./common.less"; 5 | @import "./loading.less"; 6 | @import "./markdown.less"; 7 | -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/src/types/axios.d.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2025 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import "axios"; 5 | 6 | // extend axios type 7 | declare module "axios" { 8 | export interface AxiosResponse { 9 | code: number; 10 | data: T; 11 | message: string; 12 | type?: string; 13 | showLoading?: boolean; 14 | showSuccessMsg?: boolean; 15 | successMsg?: string; 16 | [key: string]: T; 17 | } 18 | export interface AxiosRequestConfig { 19 | [key: string]: T; 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/src/views/chatbot/components/index.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2025 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import Chatbot from "./Chatbot.vue"; 5 | import ConfigDrawer from "./ConfigDrawer.vue"; 6 | import Header from "./Header.vue"; 7 | import MessageItem from "./MessageItem.vue"; 8 | import UploadFile from "./UploadFile.vue"; 9 | 10 | export { Chatbot, ConfigDrawer, Header, MessageItem, UploadFile }; 11 | -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/src/views/chatbot/type.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2025 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | export interface Benchmark { 5 | generator: string; 6 | postprocessor: string; 7 | retriever: string; 8 | } 9 | export interface IMessage { 10 | author: string; 11 | content: string; 12 | benchmark?: Benchmark | undefined; 13 | } 14 | export interface ConfigType { 15 | top_n: number; 16 | temperature: number; 17 | top_p: number; 18 | top_k: number; 19 | repetition_penalty: number; 20 | max_tokens: number; 21 | stream: boolean; 22 | } 23 | -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/src/views/pipeline/components/UpdateDialog/index.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2025 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import Activated from "./Activated.vue"; 5 | import Basic from "./Basic.vue"; 6 | import Generator from "./Generator.vue"; 7 | import Indexer from "./Indexer.vue"; 8 | import NodeParser from "./NodeParser.vue"; 9 | import PostProcessor from "./PostProcessor.vue"; 10 | import Retriever from "./Retriever.vue"; 11 | 12 | export { Activated, Basic, Generator, Indexer, NodeParser, PostProcessor, Retriever }; 13 | -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/src/views/pipeline/type.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2025 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | export interface ModelType { 5 | model_id: string; 6 | model_path: string; 7 | device: string; 8 | weight?: string; 9 | } 10 | 11 | export interface SystemType { 12 | cpuUsage: number; 13 | gpuUsage: number; 14 | diskUsage: number; 15 | memoryUsage: number; 16 | memoryUsed: string; 17 | memoryTotal: string; 18 | kernel: string; 19 | processor: string; 20 | os: string; 21 | currentTime: string; 22 | } 23 | -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/src/vite-env.d.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2025 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | /// 5 | -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "files": [], 3 | "references": [{ "path": "./tsconfig.app.json" }, { "path": "./tsconfig.node.json" }] 4 | } 5 | -------------------------------------------------------------------------------- /EdgeCraftRAG/ui/vue/tsconfig.node.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "tsBuildInfoFile": "./node_modules/.tmp/tsconfig.node.tsbuildinfo", 4 | "target": "ES2022", 5 | "lib": ["ES2023"], 6 | "module": "ESNext", 7 | "skipLibCheck": true, 8 | 9 | "moduleResolution": "bundler", 10 | "allowImportingTsExtensions": true, 11 | "isolatedModules": true, 12 | "moduleDetection": "force", 13 | "noEmit": true, 14 | 15 | "strict": true, 16 | "noUnusedLocals": true, 17 | "noUnusedParameters": true, 18 | "noFallthroughCasesInSwitch": true, 19 | "noUncheckedSideEffectImports": true 20 | }, 21 | "include": ["vite.config.ts"] 22 | } 23 | -------------------------------------------------------------------------------- /FinanceAgent/assets/fin_agent_dataprep.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/FinanceAgent/assets/fin_agent_dataprep.png -------------------------------------------------------------------------------- /FinanceAgent/assets/finance_agent_arch.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/FinanceAgent/assets/finance_agent_arch.png -------------------------------------------------------------------------------- /FinanceAgent/assets/finqa_tool.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/FinanceAgent/assets/finqa_tool.png -------------------------------------------------------------------------------- /FinanceAgent/assets/opea-agent-setting.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/FinanceAgent/assets/opea-agent-setting.png -------------------------------------------------------------------------------- /FinanceAgent/assets/opea-agent-test.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/FinanceAgent/assets/opea-agent-test.png -------------------------------------------------------------------------------- /FinanceAgent/assets/ui_connections_settings.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/FinanceAgent/assets/ui_connections_settings.png -------------------------------------------------------------------------------- /FinanceAgent/assets/upload_doc_ui.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/FinanceAgent/assets/upload_doc_ui.png -------------------------------------------------------------------------------- /GraphRAG/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | ARG BASE_TAG=latest 5 | FROM opea/comps-base:$BASE_TAG 6 | 7 | COPY ./graphrag.py $HOME/graphrag.py 8 | 9 | ENTRYPOINT ["python", "graphrag.py"] 10 | -------------------------------------------------------------------------------- /GraphRAG/assets/8microservices.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/GraphRAG/assets/8microservices.png -------------------------------------------------------------------------------- /GraphRAG/assets/img/chat_ui_init.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/GraphRAG/assets/img/chat_ui_init.png -------------------------------------------------------------------------------- /GraphRAG/assets/img/chat_ui_response.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/GraphRAG/assets/img/chat_ui_response.png -------------------------------------------------------------------------------- /GraphRAG/assets/img/chat_ui_upload.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/GraphRAG/assets/img/chat_ui_upload.png -------------------------------------------------------------------------------- /GraphRAG/assets/img/chatqna_architecture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/GraphRAG/assets/img/chatqna_architecture.png -------------------------------------------------------------------------------- /GraphRAG/assets/img/chatqna_dashboards.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/GraphRAG/assets/img/chatqna_dashboards.png -------------------------------------------------------------------------------- /GraphRAG/assets/img/chatqna_flow_chart.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/GraphRAG/assets/img/chatqna_flow_chart.png -------------------------------------------------------------------------------- /GraphRAG/assets/img/conversation_ui_init.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/GraphRAG/assets/img/conversation_ui_init.png -------------------------------------------------------------------------------- /GraphRAG/assets/img/conversation_ui_response.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/GraphRAG/assets/img/conversation_ui_response.png -------------------------------------------------------------------------------- /GraphRAG/assets/img/conversation_ui_upload.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/GraphRAG/assets/img/conversation_ui_upload.png -------------------------------------------------------------------------------- /GraphRAG/assets/img/tgi_dashboard.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/GraphRAG/assets/img/tgi_dashboard.png -------------------------------------------------------------------------------- /GraphRAG/tests/README.md: -------------------------------------------------------------------------------- 1 | # GraphRAG E2E test scripts 2 | 3 | ## Set the required environment variable 4 | 5 | ```bash 6 | export HF_TOKEN="Your_Huggingface_API_Token" 7 | ``` 8 | 9 | ## Run test 10 | 11 | On Intel Gaudi: 12 | 13 | ```bash 14 | bash test_compose_on_gaudi.sh 15 | ``` 16 | -------------------------------------------------------------------------------- /GraphRAG/ui/docker/Dockerfile.react: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | # Use node 20.11.1 as the base image 5 | FROM node:20.11.1 as vite-app 6 | 7 | COPY react /usr/app/react 8 | WORKDIR /usr/app/react 9 | 10 | RUN ["npm", "install"] 11 | RUN ["npm", "run", "build"] 12 | 13 | FROM nginx:alpine 14 | 15 | COPY --from=vite-app /usr/app/react/dist /usr/share/nginx/html 16 | COPY ./react/env.sh /docker-entrypoint.d/env.sh 17 | 18 | COPY ./react/nginx.conf /etc/nginx/conf.d/default.conf 19 | RUN chmod +x /docker-entrypoint.d/env.sh 20 | -------------------------------------------------------------------------------- /GraphRAG/ui/react/.env: -------------------------------------------------------------------------------- 1 | VITE_BACKEND_SERVICE_ENDPOINT=http://backend_address:8888/v1/chatqna 2 | VITE_DATA_PREP_SERVICE_URL=http://backend_address:6007/v1/dataprep/ingest 3 | -------------------------------------------------------------------------------- /GraphRAG/ui/react/.env.production: -------------------------------------------------------------------------------- 1 | VITE_BACKEND_SERVICE_ENDPOINT=APP_BACKEND_SERVICE_ENDPOINT 2 | VITE_DATA_PREP_SERVICE_URL=APP_DATA_PREP_SERVICE_URL 3 | -------------------------------------------------------------------------------- /GraphRAG/ui/react/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | root: true, 3 | env: { browser: true, es2020: true }, 4 | extends: ["eslint:recommended", "plugin:@typescript-eslint/recommended", "plugin:react-hooks/recommended"], 5 | ignorePatterns: ["dist", ".eslintrc.cjs"], 6 | parser: "@typescript-eslint/parser", 7 | plugins: ["react-refresh"], 8 | rules: { 9 | "react-refresh/only-export-components": ["warn", { allowConstantExport: true }], 10 | }, 11 | }; 12 | -------------------------------------------------------------------------------- /GraphRAG/ui/react/.gitignore: -------------------------------------------------------------------------------- 1 | # Logs 2 | logs 3 | *.log 4 | npm-debug.log* 5 | yarn-debug.log* 6 | yarn-error.log* 7 | pnpm-debug.log* 8 | lerna-debug.log* 9 | 10 | node_modules 11 | dist 12 | dist-ssr 13 | *.local 14 | 15 | # Editor directories and files 16 | .vscode/* 17 | !.vscode/extensions.json 18 | .idea 19 | .DS_Store 20 | *.suo 21 | *.ntvs* 22 | *.njsproj 23 | *.sln 24 | *.sw? 25 | -------------------------------------------------------------------------------- /GraphRAG/ui/react/env.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # Copyright (C) 2024 Intel Corporation 3 | # SPDX-License-Identifier: Apache-2.0 4 | 5 | for i in $(env | grep APP_) #// Make sure to use the prefix MY_APP_ if you have any other prefix in env.production file variable name replace it with MY_APP_ 6 | do 7 | key=$(echo $i | cut -d '=' -f 1) 8 | value=$(echo $i | cut -d '=' -f 2-) 9 | echo $key=$value 10 | # sed All files 11 | # find /usr/share/nginx/html -type f -exec sed -i "s|${key}|${value}|g" '{}' + 12 | 13 | # sed JS and CSS only 14 | find /usr/share/nginx/html -type f \( -name '*.js' -o -name '*.css' \) -exec sed -i "s|${key}|${value}|g" '{}' + 15 | done 16 | -------------------------------------------------------------------------------- /GraphRAG/ui/react/index.html: -------------------------------------------------------------------------------- 1 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | Conversations UI 13 | 14 | 15 |
16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /GraphRAG/ui/react/nginx.conf: -------------------------------------------------------------------------------- 1 | server { 2 | listen 80; 3 | 4 | gzip on; 5 | gzip_proxied any; 6 | gzip_comp_level 6; 7 | gzip_buffers 16 8k; 8 | gzip_http_version 1.1; 9 | gzip_types font/woff2 text/css application/javascript application/json application/font-woff application/font-tff image/gif image/png image/svg+xml application/octet-stream; 10 | 11 | location / { 12 | root /usr/share/nginx/html; 13 | index index.html index.htm; 14 | try_files $uri $uri/ /index.html =404; 15 | 16 | location ~* \.(gif|jpe?g|png|webp|ico|svg|css|js|mp4|woff2)$ { 17 | expires 1d; 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /GraphRAG/ui/react/postcss.config.cjs: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | plugins: { 3 | "postcss-preset-mantine": {}, 4 | "postcss-simple-vars": { 5 | variables: { 6 | "mantine-breakpoint-xs": "36em", 7 | "mantine-breakpoint-sm": "48em", 8 | "mantine-breakpoint-md": "62em", 9 | "mantine-breakpoint-lg": "75em", 10 | "mantine-breakpoint-xl": "88em", 11 | }, 12 | }, 13 | }, 14 | }; 15 | -------------------------------------------------------------------------------- /GraphRAG/ui/react/src/__tests__/util.test.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import { describe, expect, test } from "vitest"; 5 | import { getCurrentTimeStamp, uuidv4 } from "../common/util"; 6 | 7 | describe("unit tests", () => { 8 | test("check UUID is of length 36", () => { 9 | expect(uuidv4()).toHaveLength(36); 10 | }); 11 | test("check TimeStamp generated is of unix", () => { 12 | expect(getCurrentTimeStamp()).toBe(Math.floor(Date.now() / 1000)); 13 | }); 14 | }); 15 | -------------------------------------------------------------------------------- /GraphRAG/ui/react/src/common/client.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import axios from "axios"; 5 | 6 | //add iterceptors to add any request headers 7 | 8 | export default axios; 9 | -------------------------------------------------------------------------------- /GraphRAG/ui/react/src/common/util.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | export const getCurrentTimeStamp = () => { 5 | return Math.floor(Date.now() / 1000); 6 | }; 7 | 8 | export const uuidv4 = () => { 9 | return "10000000-1000-4000-8000-100000000000".replace(/[018]/g, (c) => 10 | (+c ^ (crypto.getRandomValues(new Uint8Array(1))[0] & (15 >> (+c / 4)))).toString(16), 11 | ); 12 | }; 13 | -------------------------------------------------------------------------------- /GraphRAG/ui/react/src/components/Message/conversationMessage.module.scss: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | @import "../../styles/styles"; 5 | 6 | .conversationMessage { 7 | @include flex(column, nowrap, flex-start, flex-start); 8 | margin-top: 16px; 9 | padding: 0 32px; 10 | width: 100%; 11 | 12 | & > * { 13 | width: 100%; 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /GraphRAG/ui/react/src/config.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | export const DATA_PREP_URL = import.meta.env.VITE_DATA_PREP_SERVICE_URL; 5 | export const CHAT_QNA_URL = import.meta.env.VITE_BACKEND_SERVICE_ENDPOINT; 6 | -------------------------------------------------------------------------------- /GraphRAG/ui/react/src/index.scss: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | @import "@mantine/core/styles.css"; 5 | 6 | :root { 7 | font-family: Inter, system-ui, Avenir, Helvetica, Arial, sans-serif; 8 | line-height: 1.5; 9 | font-weight: 400; 10 | } 11 | 12 | html, 13 | body { 14 | position: absolute; 15 | top: 0; 16 | left: 0; 17 | width: 100%; 18 | height: 100%; 19 | overflow: hidden; 20 | } 21 | -------------------------------------------------------------------------------- /GraphRAG/ui/react/src/main.tsx: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import React from "react" 5 | import ReactDOM from "react-dom/client" 6 | import App from "./App.tsx" 7 | import "./index.scss" 8 | import { Provider } from 'react-redux' 9 | import { store } from "./redux/store.ts" 10 | 11 | ReactDOM.createRoot(document.getElementById("root")!).render( 12 | 13 | 14 | 15 | 16 | 17 | ) 18 | -------------------------------------------------------------------------------- /GraphRAG/ui/react/src/redux/User/user.d.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | export interface User { 5 | name: string | null; 6 | } 7 | -------------------------------------------------------------------------------- /GraphRAG/ui/react/src/styles/components/_context.scss: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/GraphRAG/ui/react/src/styles/components/_context.scss -------------------------------------------------------------------------------- /GraphRAG/ui/react/src/styles/components/_sidebar.scss: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | @import "../layout/flex"; 5 | 6 | @mixin sidebar { 7 | @include flex(column, nowrap, flex-start, flex-start); 8 | } 9 | -------------------------------------------------------------------------------- /GraphRAG/ui/react/src/styles/components/content.scss: -------------------------------------------------------------------------------- 1 | @mixin textWrapEllipsis { 2 | text-overflow: ellipsis; 3 | white-space: nowrap; 4 | overflow: hidden; 5 | } 6 | -------------------------------------------------------------------------------- /GraphRAG/ui/react/src/styles/layout/_basics.scss: -------------------------------------------------------------------------------- 1 | @mixin absolutes { 2 | position: absolute; 3 | top: 0; 4 | left: 0; 5 | width: 100%; 6 | height: 100%; 7 | } 8 | -------------------------------------------------------------------------------- /GraphRAG/ui/react/src/styles/layout/_flex.scss: -------------------------------------------------------------------------------- 1 | @mixin flex($direction: row, $wrap: nowrap, $alignItems: center, $justifyContent: center) { 2 | display: flex; 3 | flex-flow: $direction $wrap; 4 | align-items: $alignItems; 5 | justify-content: $justifyContent; 6 | } 7 | -------------------------------------------------------------------------------- /GraphRAG/ui/react/src/styles/styles.scss: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | @import "layout/flex"; 5 | @import "layout/basics"; 6 | -------------------------------------------------------------------------------- /GraphRAG/ui/react/src/vite-env.d.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | /// 5 | -------------------------------------------------------------------------------- /GraphRAG/ui/react/tsconfig.node.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "composite": true, 4 | "skipLibCheck": true, 5 | "module": "ESNext", 6 | "moduleResolution": "bundler", 7 | "allowSyntheticDefaultImports": true, 8 | "strict": true 9 | }, 10 | "include": ["vite.config.ts"] 11 | } 12 | -------------------------------------------------------------------------------- /GraphRAG/ui/react/vite.config.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import { defineConfig } from "vitest/config"; 5 | import react from "@vitejs/plugin-react"; 6 | 7 | // https://vitejs.dev/config/ 8 | export default defineConfig({ 9 | css: { 10 | preprocessorOptions: { 11 | scss: { 12 | additionalData: `@import "./src/styles/styles.scss";`, 13 | }, 14 | }, 15 | }, 16 | plugins: [react()], 17 | server: { 18 | port: 80, 19 | }, 20 | test: { 21 | globals: true, 22 | environment: "jsdom", 23 | }, 24 | define: { 25 | "import.meta.env": process.env, 26 | }, 27 | }); 28 | -------------------------------------------------------------------------------- /GraphRAG/ui/svelte/.editorconfig: -------------------------------------------------------------------------------- 1 | [*] 2 | indent_style = tab 3 | 4 | [package.json] 5 | indent_style = space 6 | indent_size = 2 7 | 8 | [*.md] 9 | indent_style = space 10 | indent_size = 2 11 | -------------------------------------------------------------------------------- /GraphRAG/ui/svelte/.env: -------------------------------------------------------------------------------- 1 | CHAT_BASE_URL = '/v1/graphrag' 2 | 3 | UPLOAD_FILE_BASE_URL = '/v1/dataprep/ingest' 4 | 5 | GET_FILE = '/v1/dataprep/get' 6 | 7 | DELETE_FILE = '/v1/dataprep/delete' 8 | -------------------------------------------------------------------------------- /GraphRAG/ui/svelte/.eslintignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules 3 | /build 4 | /.svelte-kit 5 | /package 6 | .env 7 | .env.* 8 | !.env.example 9 | 10 | # Ignore files for PNPM, NPM and YARN 11 | pnpm-lock.yaml 12 | package-lock.json 13 | yarn.lock 14 | -------------------------------------------------------------------------------- /GraphRAG/ui/svelte/.prettierignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules 3 | /build 4 | /.svelte-kit 5 | /package 6 | .env 7 | .env.* 8 | !.env.example 9 | 10 | # Ignore files for PNPM, NPM and YARN 11 | pnpm-lock.yaml 12 | package-lock.json 13 | yarn.lock 14 | -------------------------------------------------------------------------------- /GraphRAG/ui/svelte/.prettierrc: -------------------------------------------------------------------------------- 1 | {"pluginSearchDirs": ["."], "overrides": [{"files": "*.svelte", "options": {"parser": "svelte"}}]} 2 | -------------------------------------------------------------------------------- /GraphRAG/ui/svelte/postcss.config.cjs: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | const tailwindcss = require("tailwindcss"); 5 | const autoprefixer = require("autoprefixer"); 6 | 7 | const config = { 8 | plugins: [ 9 | //Some plugins, like tailwindcss/nesting, need to run before Tailwind, 10 | tailwindcss(), 11 | //But others, like autoprefixer, need to run after, 12 | autoprefixer, 13 | ], 14 | }; 15 | 16 | module.exports = config; 17 | -------------------------------------------------------------------------------- /GraphRAG/ui/svelte/src/app.d.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // See: https://kit.svelte.dev/docs/types#app 5 | // import { Result} from "neverthrow"; 6 | interface Window { 7 | deviceType: string; 8 | } 9 | -------------------------------------------------------------------------------- /GraphRAG/ui/svelte/src/app.html: -------------------------------------------------------------------------------- 1 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | %sveltekit.head% 13 | 14 | 15 |
%sveltekit.body%
16 | 17 | 18 | -------------------------------------------------------------------------------- /GraphRAG/ui/svelte/src/lib/assets/upload/next.svelte: -------------------------------------------------------------------------------- 1 | 5 | 6 | 21 | -------------------------------------------------------------------------------- /GraphRAG/ui/svelte/src/lib/assets/upload/previous.svelte: -------------------------------------------------------------------------------- 1 | 5 | 6 | 21 | -------------------------------------------------------------------------------- /GraphRAG/ui/svelte/src/lib/modules/chat/MessageAvatar.svelte: -------------------------------------------------------------------------------- 1 | 5 | 6 | 14 | 15 | {#if role === MessageRole.User} 16 | 17 | {:else} 18 | 19 | {/if} 20 | -------------------------------------------------------------------------------- /GraphRAG/ui/svelte/src/routes/+page.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import { browser } from "$app/environment"; 5 | import { LOCAL_STORAGE_KEY } from "$lib/shared/constant/Interface"; 6 | 7 | export const load = async () => { 8 | if (browser) { 9 | const chat = localStorage.getItem(LOCAL_STORAGE_KEY.STORAGE_CHAT_KEY); 10 | 11 | return { 12 | chatMsg: JSON.parse(chat || "[]"), 13 | }; 14 | } 15 | }; 16 | -------------------------------------------------------------------------------- /GraphRAG/ui/svelte/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/GraphRAG/ui/svelte/static/favicon.png -------------------------------------------------------------------------------- /GraphRAG/ui/svelte/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./.svelte-kit/tsconfig.json", 3 | "compilerOptions": { 4 | "allowJs": true, 5 | "checkJs": true, 6 | "esModuleInterop": true, 7 | "forceConsistentCasingInFileNames": true, 8 | "resolveJsonModule": true, 9 | "skipLibCheck": true, 10 | "sourceMap": true, 11 | "strict": true, 12 | "module": "ESNext", 13 | "target": "ES6", 14 | "outDir": "./dist" 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /GraphRAG/ui/svelte/vite.config.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import { sveltekit } from "@sveltejs/kit/vite"; 5 | import type { UserConfig } from "vite"; 6 | 7 | const config: UserConfig = { 8 | plugins: [sveltekit()], 9 | server: { 10 | allowedHosts: true, 11 | }, 12 | }; 13 | 14 | export default config; 15 | -------------------------------------------------------------------------------- /HybridRAG/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2025 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | ARG BASE_TAG=latest 5 | FROM opea/comps-base:$BASE_TAG 6 | 7 | COPY ./hybridrag.py $HOME/hybridrag.py 8 | 9 | ENTRYPOINT ["python", "hybridrag.py"] 10 | 11 | -------------------------------------------------------------------------------- /HybridRAG/README_NOTICE.md: -------------------------------------------------------------------------------- 1 | # Notice for FFmpeg: 2 | 3 | FFmpeg is an open source project licensed under LGPL and GPL. See https://www.ffmpeg.org/legal.html. You are solely responsible for determining if your use of FFmpeg requires any additional licenses. Intel is not responsible for obtaining any such licenses, nor liable for any licensing fees due, in connection with your use of FFmpeg. 4 | -------------------------------------------------------------------------------- /HybridRAG/assets/img/chat_ui_init.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/HybridRAG/assets/img/chat_ui_init.png -------------------------------------------------------------------------------- /HybridRAG/assets/img/chat_ui_response.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/HybridRAG/assets/img/chat_ui_response.png -------------------------------------------------------------------------------- /HybridRAG/assets/img/chat_ui_upload.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/HybridRAG/assets/img/chat_ui_upload.png -------------------------------------------------------------------------------- /HybridRAG/assets/img/hybridrag_retriever_architecture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/HybridRAG/assets/img/hybridrag_retriever_architecture.png -------------------------------------------------------------------------------- /HybridRAG/ui/svelte/.editorconfig: -------------------------------------------------------------------------------- 1 | [*] 2 | indent_style = tab 3 | 4 | [package.json] 5 | indent_style = space 6 | indent_size = 2 7 | 8 | [*.md] 9 | indent_style = space 10 | indent_size = 2 11 | -------------------------------------------------------------------------------- /HybridRAG/ui/svelte/.env: -------------------------------------------------------------------------------- 1 | CHAT_BASE_URL = '/v1/hybridrag' 2 | 3 | UPLOAD_FILE_BASE_URL = '/v1/dataprep/ingest' 4 | 5 | GET_FILE = '/v1/dataprep/get' 6 | 7 | DELETE_FILE = '/v1/dataprep/delete' 8 | -------------------------------------------------------------------------------- /HybridRAG/ui/svelte/.eslintignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules 3 | /build 4 | /.svelte-kit 5 | /package 6 | .env 7 | .env.* 8 | !.env.example 9 | 10 | # Ignore files for PNPM, NPM and YARN 11 | pnpm-lock.yaml 12 | package-lock.json 13 | yarn.lock 14 | -------------------------------------------------------------------------------- /HybridRAG/ui/svelte/.prettierignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules 3 | /build 4 | /.svelte-kit 5 | /package 6 | .env 7 | .env.* 8 | !.env.example 9 | 10 | # Ignore files for PNPM, NPM and YARN 11 | pnpm-lock.yaml 12 | package-lock.json 13 | yarn.lock 14 | -------------------------------------------------------------------------------- /HybridRAG/ui/svelte/.prettierrc: -------------------------------------------------------------------------------- 1 | {"pluginSearchDirs": ["."], "overrides": [{"files": "*.svelte", "options": {"parser": "svelte"}}]} 2 | -------------------------------------------------------------------------------- /HybridRAG/ui/svelte/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/HybridRAG/ui/svelte/static/favicon.png -------------------------------------------------------------------------------- /HybridRAG/ui/svelte/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./.svelte-kit/tsconfig.json", 3 | "compilerOptions": { 4 | "allowJs": true, 5 | "checkJs": true, 6 | "esModuleInterop": true, 7 | "forceConsistentCasingInFileNames": true, 8 | "resolveJsonModule": true, 9 | "skipLibCheck": true, 10 | "sourceMap": true, 11 | "strict": true, 12 | "module": "ESNext", 13 | "target": "ES6", 14 | "outDir": "./dist" 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /InstructionTuning/docker_image_build/build.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | services: 5 | finetuning: 6 | build: 7 | args: 8 | http_proxy: ${http_proxy} 9 | https_proxy: ${https_proxy} 10 | no_proxy: ${no_proxy} 11 | context: GenAIComps 12 | dockerfile: comps/finetuning/src/Dockerfile 13 | image: ${REGISTRY:-opea}/finetuning:${TAG:-latest} 14 | -------------------------------------------------------------------------------- /InstructionTuning/tests/README.md: -------------------------------------------------------------------------------- 1 | # Translation E2E test scripts 2 | 3 | ## Set the required environment variable 4 | 5 | ```bash 6 | export HF_TOKEN="Your_Huggingface_API_Token" 7 | ``` 8 | 9 | ## Run test 10 | 11 | On Intel Xeon: 12 | 13 | ```bash 14 | bash test_compose_on_xeon.sh 15 | ``` 16 | -------------------------------------------------------------------------------- /MultimodalQnA/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | ARG BASE_TAG=latest 5 | FROM opea/comps-base:$BASE_TAG 6 | 7 | COPY ./multimodalqna.py $HOME/multimodalqna.py 8 | 9 | ENTRYPOINT ["python", "multimodalqna.py"] 10 | -------------------------------------------------------------------------------- /MultimodalQnA/assets/img/MultimodalQnA.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/MultimodalQnA/assets/img/MultimodalQnA.png -------------------------------------------------------------------------------- /MultimodalQnA/assets/img/audio-ingestion.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/MultimodalQnA/assets/img/audio-ingestion.png -------------------------------------------------------------------------------- /MultimodalQnA/assets/img/audio-query.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/MultimodalQnA/assets/img/audio-query.png -------------------------------------------------------------------------------- /MultimodalQnA/assets/img/image-ingestion.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/MultimodalQnA/assets/img/image-ingestion.png -------------------------------------------------------------------------------- /MultimodalQnA/assets/img/image-query-text.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/MultimodalQnA/assets/img/image-query-text.png -------------------------------------------------------------------------------- /MultimodalQnA/assets/img/image-query-tts.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/MultimodalQnA/assets/img/image-query-tts.png -------------------------------------------------------------------------------- /MultimodalQnA/assets/img/mmqna-ui.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/MultimodalQnA/assets/img/mmqna-ui.png -------------------------------------------------------------------------------- /MultimodalQnA/assets/img/pdf-ingestion.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/MultimodalQnA/assets/img/pdf-ingestion.png -------------------------------------------------------------------------------- /MultimodalQnA/assets/img/pdf-query.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/MultimodalQnA/assets/img/pdf-query.png -------------------------------------------------------------------------------- /MultimodalQnA/assets/img/vector-store.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/MultimodalQnA/assets/img/vector-store.png -------------------------------------------------------------------------------- /MultimodalQnA/assets/img/video-ingestion.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/MultimodalQnA/assets/img/video-ingestion.png -------------------------------------------------------------------------------- /MultimodalQnA/assets/img/video-query.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/MultimodalQnA/assets/img/video-query.png -------------------------------------------------------------------------------- /MultimodalQnA/ui/gradio/requirements.txt: -------------------------------------------------------------------------------- 1 | gradio>5.22.0 2 | gradio_pdf==0.0.20 3 | moviepy==1.0.3 4 | numpy==1.26.4 5 | opencv-python==4.10.0.82 6 | Pillow==10.3.0 7 | pydantic==2.10.6 8 | -------------------------------------------------------------------------------- /ProductivitySuite/assets/img/Login_page.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ProductivitySuite/assets/img/Login_page.png -------------------------------------------------------------------------------- /ProductivitySuite/assets/img/chat_qna_init.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ProductivitySuite/assets/img/chat_qna_init.png -------------------------------------------------------------------------------- /ProductivitySuite/assets/img/chatqna_with_conversation.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ProductivitySuite/assets/img/chatqna_with_conversation.png -------------------------------------------------------------------------------- /ProductivitySuite/assets/img/codegen.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ProductivitySuite/assets/img/codegen.png -------------------------------------------------------------------------------- /ProductivitySuite/assets/img/create_client.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ProductivitySuite/assets/img/create_client.png -------------------------------------------------------------------------------- /ProductivitySuite/assets/img/create_productivitysuite_realm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ProductivitySuite/assets/img/create_productivitysuite_realm.png -------------------------------------------------------------------------------- /ProductivitySuite/assets/img/create_realm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ProductivitySuite/assets/img/create_realm.png -------------------------------------------------------------------------------- /ProductivitySuite/assets/img/create_roles.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ProductivitySuite/assets/img/create_roles.png -------------------------------------------------------------------------------- /ProductivitySuite/assets/img/create_users.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ProductivitySuite/assets/img/create_users.png -------------------------------------------------------------------------------- /ProductivitySuite/assets/img/data_source.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ProductivitySuite/assets/img/data_source.png -------------------------------------------------------------------------------- /ProductivitySuite/assets/img/doc_summary.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ProductivitySuite/assets/img/doc_summary.png -------------------------------------------------------------------------------- /ProductivitySuite/assets/img/doc_summary_file.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ProductivitySuite/assets/img/doc_summary_file.png -------------------------------------------------------------------------------- /ProductivitySuite/assets/img/doc_summary_paste.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ProductivitySuite/assets/img/doc_summary_paste.png -------------------------------------------------------------------------------- /ProductivitySuite/assets/img/faq_generator.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ProductivitySuite/assets/img/faq_generator.png -------------------------------------------------------------------------------- /ProductivitySuite/assets/img/keycloak_login.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ProductivitySuite/assets/img/keycloak_login.png -------------------------------------------------------------------------------- /ProductivitySuite/assets/img/productivitysuite_client_settings.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ProductivitySuite/assets/img/productivitysuite_client_settings.png -------------------------------------------------------------------------------- /ProductivitySuite/assets/img/set_user_password.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ProductivitySuite/assets/img/set_user_password.png -------------------------------------------------------------------------------- /ProductivitySuite/assets/img/user_role_mapping.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ProductivitySuite/assets/img/user_role_mapping.png -------------------------------------------------------------------------------- /ProductivitySuite/tests/README.md: -------------------------------------------------------------------------------- 1 | # ProductivitySuite E2E test scripts 2 | 3 | ## Set the required environment variable 4 | 5 | ```bash 6 | export HF_TOKEN="Your_Huggingface_API_Token" 7 | ``` 8 | 9 | ## Run test 10 | 11 | On Intel Xeon with TGI: 12 | 13 | ```bash 14 | bash test_compose_on_xeon.sh 15 | ``` 16 | -------------------------------------------------------------------------------- /ProductivitySuite/ui/docker/Dockerfile.react: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | # Use node 20.11.1 as the base image 5 | FROM node:20.11.1 as vite-app 6 | 7 | COPY ./react /usr/app/react 8 | WORKDIR /usr/app/react 9 | 10 | 11 | RUN ["npm", "install"] 12 | RUN ["npm", "run", "build"] 13 | 14 | 15 | FROM nginx:alpine 16 | 17 | COPY --from=vite-app /usr/app/react/dist /usr/share/nginx/html 18 | COPY ./react/env.sh /docker-entrypoint.d/env.sh 19 | 20 | COPY ./react/nginx.conf /etc/nginx/conf.d/default.conf 21 | RUN chmod +x /docker-entrypoint.d/env.sh 22 | -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | root: true, 3 | env: { browser: true, es2020: true }, 4 | extends: ["eslint:recommended", "plugin:@typescript-eslint/recommended", "plugin:react-hooks/recommended"], 5 | ignorePatterns: ["dist", ".eslintrc.cjs"], 6 | parser: "@typescript-eslint/parser", 7 | plugins: ["react-refresh"], 8 | rules: { 9 | "react-refresh/only-export-components": ["warn", { allowConstantExport: true }], 10 | }, 11 | }; 12 | -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/.gitignore: -------------------------------------------------------------------------------- 1 | # Logs 2 | logs 3 | *.log 4 | npm-debug.log* 5 | yarn-debug.log* 6 | yarn-error.log* 7 | pnpm-debug.log* 8 | lerna-debug.log* 9 | 10 | node_modules 11 | dist 12 | dist-ssr 13 | *.local 14 | 15 | # Editor directories and files 16 | .vscode/* 17 | !.vscode/extensions.json 18 | .idea 19 | .DS_Store 20 | *.suo 21 | *.ntvs* 22 | *.njsproj 23 | *.sln 24 | *.sw? 25 | -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/nginx.conf: -------------------------------------------------------------------------------- 1 | server { 2 | listen 80; 3 | 4 | gzip on; 5 | gzip_proxied any; 6 | gzip_comp_level 6; 7 | gzip_buffers 16 8k; 8 | gzip_http_version 1.1; 9 | gzip_types font/woff2 text/css application/javascript application/json application/font-woff application/font-tff image/gif image/png image/svg+xml application/octet-stream; 10 | 11 | location / { 12 | root /usr/share/nginx/html; 13 | index index.html index.htm; 14 | try_files $uri $uri/ /index.html =404; 15 | 16 | location ~* \.(gif|jpe?g|png|webp|ico|svg|css|js|mp4|woff2)$ { 17 | expires 1d; 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/public/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ProductivitySuite/ui/react/public/favicon.ico -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/public/logo192.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ProductivitySuite/ui/react/public/logo192.png -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/public/logo512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ProductivitySuite/ui/react/public/logo512.png -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/public/manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "short_name": "ProductivitySuite", 3 | "name": "ProductivitySuite UI", 4 | "icons": [ 5 | { 6 | "src": "favicon.ico", 7 | "sizes": "64x64 32x32 24x24 16x16", 8 | "type": "image/x-icon" 9 | }, 10 | { 11 | "src": "logo192.png", 12 | "type": "image/png", 13 | "sizes": "192x192" 14 | }, 15 | { 16 | "src": "logo512.png", 17 | "type": "image/png", 18 | "sizes": "512x512" 19 | } 20 | ], 21 | "start_url": ".", 22 | "display": "standalone", 23 | "theme_color": "#000000", 24 | "background_color": "#ffffff" 25 | } 26 | -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/public/model_configs.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "model_name": "Intel/neural-chat-7b-v3-3", 4 | "displayName": "Intel Neural Chat", 5 | "minToken": 100, 6 | "maxToken": 2000, 7 | "types": ["chat", "summary", "code"] 8 | } 9 | ] 10 | -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/public/robots.txt: -------------------------------------------------------------------------------- 1 | # https://www.robotstxt.org/robotstxt.html 2 | User-agent: * 3 | -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/src/App.scss: -------------------------------------------------------------------------------- 1 | // Post javascript styles 2 | -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/src/__tests__/util.test.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | import { describe, expect, test } from "vitest"; 5 | import { getCurrentTimeStamp, uuidv4 } from "../common/util"; 6 | 7 | describe("unit tests", () => { 8 | test("check UUID is of length 36", () => { 9 | expect(uuidv4()).toHaveLength(36); 10 | }); 11 | test("check TimeStamp generated is of unix", () => { 12 | expect(getCurrentTimeStamp()).toBe(Math.floor(Date.now() / 1000)); 13 | }); 14 | }); 15 | -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/src/assets/icons/moon.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/src/common/util.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | export const getCurrentTimeStamp = () => { 5 | return Math.floor(Date.now() / 1000); 6 | }; 7 | 8 | export const uuidv4 = () => { 9 | return "10000000-1000-4000-8000-100000000000".replace(/[018]/g, (c) => 10 | (+c ^ (crypto.getRandomValues(new Uint8Array(1))[0] & (15 >> (+c / 4)))).toString(16), 11 | ); 12 | }; 13 | -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/src/components/Chat_Markdown/markdown.module.scss: -------------------------------------------------------------------------------- 1 | .tableDiv { 2 | &:first-of-type { 3 | padding-top: 0px !important; 4 | } 5 | 6 | table, 7 | th, 8 | td { 9 | border: 1px solid black; 10 | border-collapse: collapse; 11 | padding: 5px; 12 | } 13 | } 14 | 15 | .md { 16 | li { 17 | margin-left: 35px; /* Adjust the value based on your preference */ 18 | } 19 | } 20 | 21 | .markdownWrapper { 22 | > p:first-of-type { 23 | margin-top: 0.25rem; 24 | } 25 | 26 | > p:last-of-type { 27 | margin-bottom: 0.25rem; 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/src/components/Chat_SettingsModal/ChatSettingsModal.module.scss: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/ProductivitySuite/ui/react/src/components/Chat_SettingsModal/ChatSettingsModal.module.scss -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/src/components/Chat_User/ChatUser.module.scss: -------------------------------------------------------------------------------- 1 | .userWrapper { 2 | display: flex; 3 | justify-content: flex-end; 4 | margin-bottom: 2rem; 5 | position: relative; 6 | 7 | .userPrompt { 8 | max-width: 80%; 9 | border-radius: var(--input-radius); 10 | padding: 0.75rem 2rem 0.75rem 1rem; 11 | overflow-wrap: break-word; 12 | word-wrap: break-word; 13 | word-break: break-word; 14 | } 15 | 16 | .addIcon { 17 | position: absolute; 18 | right: -16px; 19 | top: 3px; 20 | opacity: 0; 21 | transition: opacity 0.3s; 22 | } 23 | 24 | &:hover .addIcon { 25 | opacity: 1; 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/src/components/ProgressIcon/ProgressIcon.tsx: -------------------------------------------------------------------------------- 1 | import { CircularProgress, styled } from "@mui/material"; 2 | 3 | const ProgressIconStyle = styled(CircularProgress)(({ theme }) => ({ 4 | "svg circle": { 5 | stroke: theme.customStyles.audioProgress?.stroke, 6 | }, 7 | })); 8 | 9 | const ProgressIcon = () => { 10 | return ; 11 | }; 12 | 13 | export default ProgressIcon; 14 | -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/src/components/SearchInput/SearchInput.module.scss: -------------------------------------------------------------------------------- 1 | .searchInput { 2 | width: 100%; 3 | margin-bottom: 1rem; 4 | border-radius: var(--input-radius); 5 | border: 0; 6 | margin-bottom: 2rem; 7 | 8 | &:focus { 9 | outline: none; 10 | } 11 | 12 | :global { 13 | .MuiInputBase-root { 14 | border-radius: var(--input-radius); 15 | } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/src/components/Summary_WebInput/WebInput.module.scss: -------------------------------------------------------------------------------- 1 | .inputWrapper { 2 | width: 100%; 3 | max-width: 700px; 4 | margin-top: 1rem; 5 | } 6 | 7 | .dataList { 8 | width: 100%; 9 | margin-top: 2rem; 10 | max-height: 300; 11 | overflow: auto; 12 | border: 1px solid; 13 | border-radius: 8px; 14 | padding: 1rem; 15 | 16 | li:not(:last-of-type) { 17 | margin-bottom: 1rem; 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/src/keycloak.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2025 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | //@ts-ignore 5 | import Keycloak from "keycloak-js"; 6 | 7 | import { KEYCLOAK_SERVICE_URL } from "@root/config"; 8 | 9 | const keyCloakConfig = { 10 | url: KEYCLOAK_SERVICE_URL, 11 | realm: "productivitysuite", 12 | clientId: "productivitysuite", 13 | }; 14 | 15 | const keycloak = new Keycloak(keyCloakConfig); 16 | 17 | export default keycloak; 18 | -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/src/layouts/Main/MainLayout.module.scss: -------------------------------------------------------------------------------- 1 | .mainLayout { 2 | height: 100%; 3 | display: flex; 4 | flex-direction: column; 5 | max-height: 100%; 6 | overflow: hidden; 7 | } 8 | 9 | .mainWrapper { 10 | display: flex; 11 | flex-direction: row; 12 | flex-grow: 1; 13 | max-height: 100%; 14 | overflow: auto; 15 | overflow-x: hidden; 16 | } 17 | 18 | .contentWrapper { 19 | max-height: 100%; 20 | width: 100%; 21 | } 22 | -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/src/layouts/Minimal/MinimalLayout.module.scss: -------------------------------------------------------------------------------- 1 | .minimalLayout { 2 | display: flex; 3 | flex-direction: column; 4 | align-items: center; 5 | justify-content: center; 6 | height: 100%; 7 | width: 100%; 8 | padding: 2rem; 9 | text-align: center; 10 | } 11 | -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/src/layouts/Minimal/MinimalLayout.tsx: -------------------------------------------------------------------------------- 1 | // About pages or privacy policy are likely minimal layouts 2 | import { Outlet } from "react-router-dom"; 3 | import styles from "./MinimalLayout.module.scss"; 4 | 5 | const MinimalLayout = () => { 6 | return ( 7 |
8 | 9 |
10 | ); 11 | }; 12 | 13 | export default MinimalLayout; 14 | -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/src/redux/User/user.d.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2025 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | export interface User { 5 | name: string; 6 | isAuthenticated: boolean; 7 | role: "Admin" | "User"; 8 | } 9 | -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/src/types/common.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2025 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | export interface ErrorResponse { 5 | response?: { 6 | data?: { 7 | error?: { 8 | message?: string; 9 | }; 10 | }; 11 | }; 12 | message: string; 13 | } 14 | -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/src/types/global.d.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2025 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | declare module "*.svg" { 5 | const content: string; 6 | export default content; 7 | } 8 | -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/src/types/styles.d.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2025 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | declare module "*.module.scss" { 5 | const classes: { [key: string]: string }; 6 | export default classes; 7 | } 8 | -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/src/vite-env.d.ts: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2025 Intel Corporation 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | /// 5 | /// 6 | -------------------------------------------------------------------------------- /ProductivitySuite/ui/react/tsconfig.node.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "composite": true, 4 | "skipLibCheck": true, 5 | "module": "ESNext", 6 | "moduleResolution": "bundler", 7 | "allowSyntheticDefaultImports": true, 8 | "strict": true 9 | }, 10 | "include": ["vite.config.ts"] 11 | } 12 | -------------------------------------------------------------------------------- /SearchQnA/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | ARG BASE_TAG=latest 5 | FROM opea/comps-base:$BASE_TAG 6 | 7 | COPY ./searchqna.py $HOME/searchqna.py 8 | 9 | ENTRYPOINT ["python", "searchqna.py"] 10 | -------------------------------------------------------------------------------- /SearchQnA/assets/img/search_ui_init.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/SearchQnA/assets/img/search_ui_init.png -------------------------------------------------------------------------------- /SearchQnA/assets/img/searchqna-ui-response-example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/SearchQnA/assets/img/searchqna-ui-response-example.png -------------------------------------------------------------------------------- /SearchQnA/assets/img/searchqna-ui-starting-page.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/SearchQnA/assets/img/searchqna-ui-starting-page.png -------------------------------------------------------------------------------- /SearchQnA/assets/img/searchqna.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/SearchQnA/assets/img/searchqna.png -------------------------------------------------------------------------------- /SearchQnA/kubernetes/helm/cpu-values.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | tgi: 5 | LLM_MODEL_ID: Intel/neural-chat-7b-v3-3 6 | llm_uservice: 7 | LLM_MODEL_ID: Intel/neural-chat-7b-v3-3 8 | -------------------------------------------------------------------------------- /SearchQnA/tests/README.md: -------------------------------------------------------------------------------- 1 | # SearchQnA E2E test scripts 2 | 3 | ## Set the required environment variable 4 | 5 | ```bash 6 | export HF_TOKEN="Your_Huggingface_API_Token" 7 | ``` 8 | 9 | ## Run test 10 | 11 | On Intel Xeon with TGI: 12 | 13 | ```bash 14 | bash test_compose_on_xeon.sh 15 | ``` 16 | 17 | On Intel Gaudi with TGI: 18 | 19 | ```bash 20 | bash test_compose_on_gaudi.sh 21 | ``` 22 | 23 | On AMD ROCm with TGI: 24 | 25 | ```bash 26 | bash test_compose_on_rocm.sh 27 | ``` 28 | 29 | On AMD ROCm with vLLM: 30 | 31 | ```bash 32 | bash test_compose_vllm_on_rocm.sh 33 | ``` 34 | -------------------------------------------------------------------------------- /SearchQnA/ui/svelte/.editorconfig: -------------------------------------------------------------------------------- 1 | [*] 2 | indent_style = tab 3 | 4 | [package.json] 5 | indent_style = space 6 | indent_size = 2 7 | 8 | [*.md] 9 | indent_style = space 10 | indent_size = 2 11 | -------------------------------------------------------------------------------- /SearchQnA/ui/svelte/.env: -------------------------------------------------------------------------------- 1 | BACKEND_BASE_URL = '/v1/searchqna' 2 | -------------------------------------------------------------------------------- /SearchQnA/ui/svelte/.eslintignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules 3 | /build 4 | /.svelte-kit 5 | /package 6 | .env 7 | .env.* 8 | !.env.example 9 | 10 | # Ignore files for PNPM, NPM and YARN 11 | pnpm-lock.yaml 12 | package-lock.json 13 | yarn.lock 14 | -------------------------------------------------------------------------------- /SearchQnA/ui/svelte/.prettierignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules 3 | /build 4 | /.svelte-kit 5 | /package 6 | .env 7 | .env.* 8 | !.env.example 9 | 10 | # Ignore files for PNPM, NPM and YARN 11 | pnpm-lock.yaml 12 | package-lock.json 13 | yarn.lock 14 | -------------------------------------------------------------------------------- /SearchQnA/ui/svelte/.prettierrc: -------------------------------------------------------------------------------- 1 | {"pluginSearchDirs": ["."], "overrides": [{"files": "*.svelte", "options": {"parser": "svelte"}}]} 2 | -------------------------------------------------------------------------------- /SearchQnA/ui/svelte/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/SearchQnA/ui/svelte/static/favicon.png -------------------------------------------------------------------------------- /SearchQnA/ui/svelte/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./.svelte-kit/tsconfig.json", 3 | "compilerOptions": { 4 | "allowJs": true, 5 | "checkJs": true, 6 | "esModuleInterop": true, 7 | "forceConsistentCasingInFileNames": true, 8 | "resolveJsonModule": true, 9 | "skipLibCheck": true, 10 | "sourceMap": true, 11 | "strict": true 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /Text2Image/assets/img/text2img_init.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/Text2Image/assets/img/text2img_init.png -------------------------------------------------------------------------------- /Text2Image/assets/img/text2img_response.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/Text2Image/assets/img/text2img_response.png -------------------------------------------------------------------------------- /Text2Image/kubernetes/helm/cpu-values.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2025 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | text2image: 5 | image: 6 | repository: opea/text2image 7 | -------------------------------------------------------------------------------- /Text2Image/ui/svelte/.editorconfig: -------------------------------------------------------------------------------- 1 | [*] 2 | indent_style = tab 3 | 4 | [package.json] 5 | indent_style = space 6 | indent_size = 2 7 | 8 | [*.md] 9 | indent_style = space 10 | indent_size = 2 11 | -------------------------------------------------------------------------------- /Text2Image/ui/svelte/.env: -------------------------------------------------------------------------------- 1 | BASE_URL = '/v1/text2image' 2 | 3 | -------------------------------------------------------------------------------- /Text2Image/ui/svelte/.eslintignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules 3 | /build 4 | /.svelte-kit 5 | /package 6 | .env 7 | .env.* 8 | !.env.example 9 | 10 | # Ignore files for PNPM, NPM and YARN 11 | pnpm-lock.yaml 12 | package-lock.json 13 | yarn.lock 14 | -------------------------------------------------------------------------------- /Text2Image/ui/svelte/.prettierignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules 3 | /build 4 | /.svelte-kit 5 | /package 6 | .env 7 | .env.* 8 | !.env.example 9 | 10 | # Ignore files for PNPM, NPM and YARN 11 | pnpm-lock.yaml 12 | package-lock.json 13 | yarn.lock 14 | -------------------------------------------------------------------------------- /Text2Image/ui/svelte/.prettierrc: -------------------------------------------------------------------------------- 1 | {"pluginSearchDirs": ["."], "overrides": [{"files": "*.svelte", "options": {"parser": "svelte"}}]} 2 | -------------------------------------------------------------------------------- /Text2Image/ui/svelte/src/routes/+page.ts: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2024 Intel Corporation 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"); 4 | // you may not use this file except in compliance with the License. 5 | // You may obtain a copy of the License at 6 | // 7 | // http://www.apache.org/licenses/LICENSE-2.0 8 | // 9 | // Unless required by applicable law or agreed to in writing, software 10 | // distributed under the License is distributed on an "AS IS" BASIS, 11 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 | // See the License for the specific language governing permissions and 13 | // limitations under the License. 14 | -------------------------------------------------------------------------------- /Text2Image/ui/svelte/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/Text2Image/ui/svelte/static/favicon.png -------------------------------------------------------------------------------- /Text2Image/ui/svelte/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./.svelte-kit/tsconfig.json", 3 | "compilerOptions": { 4 | "allowJs": true, 5 | "checkJs": true, 6 | "esModuleInterop": true, 7 | "forceConsistentCasingInFileNames": true, 8 | "resolveJsonModule": true, 9 | "skipLibCheck": true, 10 | "sourceMap": true, 11 | "strict": true 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /Translation/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | ARG BASE_TAG=latest 5 | FROM opea/comps-base:$BASE_TAG 6 | 7 | COPY ./translation.py $HOME/translation.py 8 | 9 | ENTRYPOINT ["python", "translation.py"] 10 | -------------------------------------------------------------------------------- /Translation/assets/img/trans_ui_init.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/Translation/assets/img/trans_ui_init.png -------------------------------------------------------------------------------- /Translation/assets/img/trans_ui_select.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/Translation/assets/img/trans_ui_select.png -------------------------------------------------------------------------------- /Translation/assets/img/translation-ui-response-example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/Translation/assets/img/translation-ui-response-example.png -------------------------------------------------------------------------------- /Translation/assets/img/translation-ui-starting-page.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/Translation/assets/img/translation-ui-starting-page.png -------------------------------------------------------------------------------- /Translation/assets/img/translation_architecture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/Translation/assets/img/translation_architecture.png -------------------------------------------------------------------------------- /Translation/tests/README.md: -------------------------------------------------------------------------------- 1 | # Translation E2E test scripts 2 | 3 | ## Set the required environment variable 4 | 5 | ```bash 6 | export HF_TOKEN="Your_Huggingface_API_Token" 7 | ``` 8 | 9 | ## Run test 10 | 11 | On Intel Xeon with TGI: 12 | 13 | ```bash 14 | bash test_compose_on_xeon.sh 15 | ``` 16 | 17 | On Intel Gaudi with TGI: 18 | 19 | ```bash 20 | bash test_compose_on_gaudi.sh 21 | ``` 22 | 23 | On AMD ROCm with TGI: 24 | 25 | ```bash 26 | bash test_compose_on_rocm.sh 27 | ``` 28 | 29 | On AMD ROCm with vLLM: 30 | 31 | ```bash 32 | bash test_compose_vllm_on_rocm.sh 33 | ``` 34 | -------------------------------------------------------------------------------- /Translation/ui/svelte/.env: -------------------------------------------------------------------------------- 1 | BASE_URL = '/v1/translation' 2 | -------------------------------------------------------------------------------- /Translation/ui/svelte/.gitignore: -------------------------------------------------------------------------------- 1 | */node_modules 2 | /build 3 | /dist 4 | */.svelte-kit 5 | 6 | -------------------------------------------------------------------------------- /Translation/ui/svelte/.npmrc: -------------------------------------------------------------------------------- 1 | engine-strict=true 2 | -------------------------------------------------------------------------------- /Translation/ui/svelte/src/app.pcss: -------------------------------------------------------------------------------- 1 | /* Write your global styles here, in PostCSS syntax */ 2 | @tailwind base; 3 | @tailwind components; 4 | @tailwind utilities; 5 | -------------------------------------------------------------------------------- /Translation/ui/svelte/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/Translation/ui/svelte/static/favicon.png -------------------------------------------------------------------------------- /Translation/ui/svelte/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./.svelte-kit/tsconfig.json", 3 | "compilerOptions": { 4 | "allowJs": true, 5 | "checkJs": true, 6 | "esModuleInterop": true, 7 | "forceConsistentCasingInFileNames": true, 8 | "resolveJsonModule": true, 9 | "skipLibCheck": true, 10 | "sourceMap": true, 11 | "strict": true, 12 | "module": "NodeNext", 13 | "moduleResolution": "NodeNext" 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /VideoQnA/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | ARG BASE_TAG=latest 5 | FROM opea/comps-base:$BASE_TAG 6 | 7 | COPY ./videoqna.py $HOME/videoqna.py 8 | 9 | ENTRYPOINT ["python", "videoqna.py"] 10 | -------------------------------------------------------------------------------- /VideoQnA/assets/img/videoqna.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/VideoQnA/assets/img/videoqna.gif -------------------------------------------------------------------------------- /VideoQnA/docker_compose/intel/cpu/xeon/data/op_1_0320241830.mp4: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/VideoQnA/docker_compose/intel/cpu/xeon/data/op_1_0320241830.mp4 -------------------------------------------------------------------------------- /VideoQnA/ui/docker/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | FROM python:3.9-slim 5 | 6 | WORKDIR /app 7 | 8 | RUN apt-get update && apt-get install -y curl && \ 9 | rm -rf /var/lib/apt/lists/* 10 | 11 | 12 | RUN pip install --no-cache-dir --upgrade pip setuptools && \ 13 | pip install --no-cache-dir streamlit 14 | 15 | COPY ui.py /app/ui.py 16 | 17 | EXPOSE 5173 18 | 19 | HEALTHCHECK CMD curl --fail http://localhost:5173/_stcore/health 20 | 21 | ENTRYPOINT ["streamlit", "run", "ui.py", "--server.port=5173", "--server.address=0.0.0.0"] 22 | -------------------------------------------------------------------------------- /VisualQnA/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | ARG IMAGE_REPO=opea 5 | ARG BASE_TAG=latest 6 | FROM $IMAGE_REPO/comps-base:$BASE_TAG 7 | 8 | COPY ./visualqna.py $HOME/visualqna.py 9 | 10 | ENTRYPOINT ["python", "visualqna.py"] 11 | -------------------------------------------------------------------------------- /VisualQnA/assets/img/llava_screenshot1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/VisualQnA/assets/img/llava_screenshot1.png -------------------------------------------------------------------------------- /VisualQnA/assets/img/llava_screenshot2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/VisualQnA/assets/img/llava_screenshot2.png -------------------------------------------------------------------------------- /VisualQnA/assets/img/visualqna-ui-result-page.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/VisualQnA/assets/img/visualqna-ui-result-page.png -------------------------------------------------------------------------------- /VisualQnA/assets/img/visualqna-ui-starting-page.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/VisualQnA/assets/img/visualqna-ui-starting-page.png -------------------------------------------------------------------------------- /VisualQnA/assets/img/vqa.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/VisualQnA/assets/img/vqa.png -------------------------------------------------------------------------------- /VisualQnA/kubernetes/helm/cpu-tgi-values.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2025 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | tgi: 5 | enabled: true 6 | vllm: 7 | enabled: false 8 | lvm-uservice: 9 | LVM_BACKEND: "TGI" 10 | -------------------------------------------------------------------------------- /VisualQnA/kubernetes/helm/cpu-values.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2025 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | vllm: 5 | enabled: true 6 | tgi: 7 | enabled: false 8 | lvm-uservice: 9 | LVM_BACKEND: "vLLM" 10 | -------------------------------------------------------------------------------- /VisualQnA/ui/svelte/.editorconfig: -------------------------------------------------------------------------------- 1 | [*] 2 | indent_style = tab 3 | 4 | [package.json] 5 | indent_style = space 6 | indent_size = 2 7 | 8 | [*.md] 9 | indent_style = space 10 | indent_size = 2 11 | -------------------------------------------------------------------------------- /VisualQnA/ui/svelte/.env: -------------------------------------------------------------------------------- 1 | BACKEND_BASE_URL = '/v1/visualqna' 2 | -------------------------------------------------------------------------------- /VisualQnA/ui/svelte/.eslintignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules 3 | /build 4 | /.svelte-kit 5 | /package 6 | .env 7 | .env.* 8 | !.env.example 9 | 10 | # Ignore files for PNPM, NPM and YARN 11 | pnpm-lock.yaml 12 | package-lock.json 13 | yarn.lock 14 | -------------------------------------------------------------------------------- /VisualQnA/ui/svelte/.prettierignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules 3 | /build 4 | /.svelte-kit 5 | /package 6 | .env 7 | .env.* 8 | !.env.example 9 | 10 | # Ignore files for PNPM, NPM and YARN 11 | pnpm-lock.yaml 12 | package-lock.json 13 | yarn.lock 14 | -------------------------------------------------------------------------------- /VisualQnA/ui/svelte/.prettierrc: -------------------------------------------------------------------------------- 1 | {"pluginSearchDirs": ["."], "overrides": [{"files": "*.svelte", "options": {"parser": "svelte"}}]} 2 | -------------------------------------------------------------------------------- /VisualQnA/ui/svelte/src/lib/assets/imageData/extreme_ironing.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/VisualQnA/ui/svelte/src/lib/assets/imageData/extreme_ironing.png -------------------------------------------------------------------------------- /VisualQnA/ui/svelte/src/lib/assets/imageData/waterview.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/VisualQnA/ui/svelte/src/lib/assets/imageData/waterview.png -------------------------------------------------------------------------------- /VisualQnA/ui/svelte/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/opea-project/GenAIExamples/a0a6aa41afabdedbe3bb050fe9f757c2e687035c/VisualQnA/ui/svelte/static/favicon.png -------------------------------------------------------------------------------- /VisualQnA/ui/svelte/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./.svelte-kit/tsconfig.json", 3 | "compilerOptions": { 4 | "allowJs": true, 5 | "checkJs": true, 6 | "esModuleInterop": true, 7 | "forceConsistentCasingInFileNames": true, 8 | "resolveJsonModule": true, 9 | "skipLibCheck": true, 10 | "sourceMap": true, 11 | "strict": true 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /WorkflowExecAgent/docker_image_build/build.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | services: 5 | agent: 6 | build: 7 | context: GenAIComps 8 | dockerfile: comps/agent/src/Dockerfile 9 | args: 10 | http_proxy: ${http_proxy} 11 | https_proxy: ${https_proxy} 12 | no_proxy: ${no_proxy} 13 | image: ${REGISTRY:-opea}/agent:${TAG:-latest} 14 | -------------------------------------------------------------------------------- /WorkflowExecAgent/tools/components/component.py: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | 5 | class Component: 6 | def __init__(self, request_handler): 7 | self.request_handler = request_handler 8 | 9 | def _make_request(self, *args, **kwargs): 10 | return self.request_handler._make_request(*args, **kwargs) 11 | -------------------------------------------------------------------------------- /WorkflowExecAgent/tools/custom_prompt.py: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | REACT_SYS_MESSAGE = """\ 5 | You are a helpful assistant. You are to start the workflow using the tool provided. 6 | After the workflow is completed, you will use the output data to answer the user's original question in a one short sentence. 7 | 8 | Now begin! 9 | """ 10 | -------------------------------------------------------------------------------- /WorkflowExecAgent/tools/sdk.py: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | import os 5 | 6 | from tools.components.workflow import Workflow 7 | from tools.utils.handle_requests import RequestHandler 8 | 9 | 10 | class EasyDataSDK: 11 | def __init__(self): 12 | self.request_handler = RequestHandler(os.environ["SDK_BASE_URL"], os.environ["SERVING_TOKEN"]) 13 | 14 | def create_workflow(self, workflow_id=None, workflow_key=None): 15 | return Workflow( 16 | self.request_handler, 17 | workflow_id=workflow_id, 18 | workflow_key=workflow_key, 19 | ) 20 | -------------------------------------------------------------------------------- /WorkflowExecAgent/tools/tools.yaml: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2024 Intel Corporation 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | workflow_executor: 5 | description: "Starts a workflow with the given workflow id and params. Gets the output result of the workflow." 6 | callable_api: tools.py:workflow_executor 7 | args_schema: 8 | workflow_id: 9 | type: int 10 | description: Workflow id 11 | params: 12 | type: dict 13 | description: Workflow parameters. 14 | return_output: workflow_data 15 | -------------------------------------------------------------------------------- /requirements.txt: -------------------------------------------------------------------------------- 1 | kubernetes 2 | locust 3 | numpy 4 | opea-eval>=1.3 5 | prometheus_client 6 | pytest 7 | pyyaml 8 | requests 9 | sseclient-py 10 | transformers 11 | --------------------------------------------------------------------------------