Skip to content
This repository was archived by the owner on Apr 6, 2026. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ OPENAI_API_KEY=
RAG_OPENAI_EMBEDDING_MODEL=text-embedding-3-large

# Ollama configuration (local LLM server)
OLLAMA_BASE_URL=http://localhost:11434
OLLAMA_BASE_URL=http://host.docker.internal:11434
RAG_OLLAMA_MODEL=llama3:8b

# Optional
Expand Down
2 changes: 1 addition & 1 deletion backend_python/rag_engine.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
RAG_CLAUDE_MODEL = os.getenv("RAG_CLAUDE_MODEL", "claude-3-5-sonnet-20240620")
RAG_GEMINI_EMBEDDING_MODEL = os.getenv("RAG_GEMINI_EMBEDDING_MODEL", "models/embedding-001")
RAG_OPENAI_EMBEDDING_MODEL = os.getenv("RAG_OPENAI_EMBEDDING_MODEL", "text-embedding-3-large")
OLLAMA_BASE_URL = os.getenv("OLLAMA_BASE_URL", "http://172.17.0.1:11434")
OLLAMA_BASE_URL = os.getenv("OLLAMA_BASE_URL", "http://host.docker.internal:11434")
RAG_OLLAMA_MODEL = os.getenv("RAG_OLLAMA_MODEL", "llama3:8b")
CHROMA_PATH = os.getenv("CHROMA_PATH", "/app/chroma_db")
CHROMA_HOST = os.getenv("CHROMA_HOST", "")
Expand Down
3 changes: 3 additions & 0 deletions front/about.html
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,9 @@ <h4 data-i18n="resources_title">Ресурсы</h4>

</aside>
</div>
<footer class="site-footer">
<p data-i18n="footer_text">&copy; 2026 Архив Памяти. Открытая энциклопедия жертв политических репрессий.</p>
</footer>

<script src="i18n.js"></script>
<script src="header-auth.js"></script>
Expand Down
2 changes: 1 addition & 1 deletion front/admin.html
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ <h3 data-i18n="admin_moderation_title">Модерация предложений
</div>

<footer class="site-footer">
<p>&copy; 2024 Архив Памяти</p>
<p>&copy; 2026 Архив Памяти</p>
</footer>

<script src="i18n.js"></script>
Expand Down
2 changes: 1 addition & 1 deletion front/chat.html
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ <h4>Статистика</h4>
</main>

<footer class="site-footer">
<p>&copy; 2024 Архив Памяти</p>
<p>&copy; 2026 Архив Памяти</p>
</footer>

<script src="i18n.js"></script>
Expand Down
2 changes: 1 addition & 1 deletion front/contacts.html
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ <h2 data-i18n="contacts_title">Контакты</h2>
</div>

<footer class="site-footer">
<p data-i18n="footer_short">&copy; 2024 Архив Памяти</p>
<p data-i18n="footer_short">&copy; 2026 Архив Памяти</p>
</footer>

<script src="i18n.js"></script>
Expand Down
48 changes: 24 additions & 24 deletions front/i18n.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,14 @@ const translations = {
site_title: "АРХИВ ПАМЯТИ",
search_placeholder: "Поиск по имени, фамилии, году...",
search_btn: "Найти",
hero_find: "Найти человека",
hero_find: "Спросить у ИИ-ассистента",
hero_find_desc: "Введите имя или фамилию в строку поиска, чтобы найти информацию о жертве репрессий.",
hero_add: "Добавить сведения",
hero_add_desc: "Помогите дополнить архив — загрузите документы и воспоминания о ваших родственниках.",
hero_help: "Помочь проекту",
hero_help_desc: "Станьте волонтёром или поддержите проект. Каждый вклад помогает сохранить память.",
footer_text: "© 2024 Архив Памяти. Открытая энциклопедия жертв политических репрессий.",
footer_short: "© 2024 Архив Памяти",
footer_text: "© 2026 Архив Памяти. Открытая энциклопедия жертв политических репрессий.",
footer_short: "© 2026 Архив Памяти",
btn_register: "Регистрация",
btn_login: "Войти",
btn_logout: "Выйти",
Expand Down Expand Up @@ -159,11 +159,11 @@ const translations = {
admin_no_suggestions: "Предложений нет",
common_approve: "Одобрить",
common_reject: "Отклонить",
about_partner_1: "Государственный архив РФ",
about_partner_1: "Государственный архив КР",
about_partner_2: "Мемориал",
about_partner_3: "Сахаровский центр",
about_partner_3: "КТМУ",
about_partner_4: "РГАСПИ",
about_partner_5: "Яд Вашем",
about_partner_5: "БГУ",
about_partner_6: "Национальный архив РК",
about_stats_records: "Записей в базе",
about_stats_documents: "Документов в базе",
Expand Down Expand Up @@ -200,14 +200,14 @@ const translations = {
site_title: "ЭС КУРЖУНУ",
search_placeholder: "Аты-жөнү, жыл боюнча издөө...",
search_btn: "Издөө",
hero_find: "Адамды табуу",
hero_find: "ЖИке суроо",
hero_find_desc: "Репрессия курмандыгы жөнүндө маалымат табуу үчүн издөө тилкесине аты-жөнүн киргизиңиз.",
hero_add: "Маалымат кошуу",
hero_add_desc: "Архивди толуктоого жардам бериңиз — туугандарыңыз тууралуу документтерди жана эскерүүлөрдү жүктөңүз.",
hero_help: "Долбоорго жардам",
hero_help_desc: "Ыктыярчы болуңуз же долбоорду колдоңуз. Ар бир салым эс-тутумду сактоого жардам берет.",
footer_text: "© 2024 Эс Куржуну. Саясий репрессия курмандыктарынын ачык энциклопедиясы.",
footer_short: "© 2024 Эс Куржуну",
footer_text: "© 2026 Эс Куржуну. Саясий репрессия курмандыктарынын ачык энциклопедиясы.",
footer_short: "© 2026 Эс Куржуну",
btn_register: "Катталуу",
btn_login: "Кирүү",
btn_logout: "Чыгуу",
Expand Down Expand Up @@ -349,11 +349,11 @@ const translations = {
admin_no_suggestions: "Сунуштар жок",
common_approve: "Бекитүү",
common_reject: "Четке кагуу",
about_partner_1: "РФ мамлекеттик архиви",
about_partner_1: "КР мамлекеттик архиви",
about_partner_2: "Мемориал",
about_partner_3: "Сахаров борбору",
about_partner_3: "КТМУ",
about_partner_4: "РГАСПИ",
about_partner_5: "Яд Вашем",
about_partner_5: "БГУ",
about_partner_6: "КР Улуттук архиви",
about_stats_records: "Базадагы жазуулар",
about_stats_documents: "Базадагы документтер",
Expand Down Expand Up @@ -390,14 +390,14 @@ const translations = {
site_title: "MEMORY ARCHIVE",
search_placeholder: "Search by name, surname, year...",
search_btn: "Search",
hero_find: "Find a Person",
hero_find: "Ask AI-assistant",
Copy link

Copilot AI Apr 4, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

English UI copy: “Ask AI-assistant” is grammatically incorrect/unnatural. Consider changing to “Ask an AI assistant” (or “Ask the AI assistant”) for readability and consistency.

Suggested change
hero_find: "Ask AI-assistant",
hero_find: "Ask an AI assistant",

Copilot uses AI. Check for mistakes.
hero_find_desc: "Enter a name or surname in the search bar to find information about victims of repression.",
hero_add: "Add Information",
hero_add_desc: "Help expand the archive by uploading documents and memories about your relatives.",
hero_help: "Support the Project",
hero_help_desc: "Become a volunteer or support the project. Every contribution helps preserve memory.",
footer_text: "© 2024 Memory Archive. Open encyclopedia of political repression victims.",
footer_short: "© 2024 Memory Archive",
footer_text: "© 2026 Memory Archive. Open encyclopedia of political repression victims.",
footer_short: "© 2026 Memory Archive",
btn_register: "Register",
btn_login: "Login",
btn_logout: "Logout",
Expand Down Expand Up @@ -539,11 +539,11 @@ const translations = {
admin_no_suggestions: "No suggestions",
common_approve: "Approve",
common_reject: "Reject",
about_partner_1: "State Archive of the Russian Federation",
about_partner_1: "State Archive of the Kyrgyz Republic",
about_partner_2: "Memorial",
about_partner_3: "Sakharov Center",
about_partner_3: "KTMU",
about_partner_4: "RGASPI",
about_partner_5: "Yad Vashem",
about_partner_5: "BSU",
about_partner_6: "National Archive of the Kyrgyz Republic",
about_stats_records: "Records in database",
about_stats_documents: "Documents in database",
Expand Down Expand Up @@ -580,14 +580,14 @@ const translations = {
site_title: "HAFIZA ARŞİVİ",
search_placeholder: "Ad, soyad, yıl ile ara...",
search_btn: "Ara",
hero_find: "Kişi Bul",
hero_find: "Yapay zekaya sorun",
hero_find_desc: "Baskı mağdurları hakkında bilgi bulmak için arama çubuğuna ad veya soyad girin.",
hero_add: "Bilgi Ekle",
hero_add_desc: "Arşivi büyütmeye yardımcı olun; yakınlarınızla ilgili belgeleri ve anıları yükleyin.",
hero_help: "Projeyi Destekle",
hero_help_desc: "Gönüllü olun veya projeyi destekleyin. Her katkı hafızayı korumaya yardımcı olur.",
footer_text: "© 2024 Hafıza Arşivi. Siyasi baskı mağdurlarının açık ansiklopedisi.",
footer_short: "© 2024 Hafıza Arşivi",
footer_text: "© 2026 Hafıza Arşivi. Siyasi baskı mağdurlarının açık ansiklopedisi.",
footer_short: "© 2026 Hafıza Arşivi",
btn_register: "Kayıt Ol",
btn_login: "Giriş Yap",
btn_logout: "Çıkış Yap",
Expand Down Expand Up @@ -729,11 +729,11 @@ const translations = {
admin_no_suggestions: "Öneri yok",
common_approve: "Onayla",
common_reject: "Reddet",
about_partner_1: "Rusya Federasyonu Devlet Arşivi",
about_partner_1: "Kırgızistan Cumhuriyeti Devlet Arşivleri",
about_partner_2: "Memorial",
about_partner_3: "Sakharov Merkezi",
about_partner_3: "KTMÜ",
about_partner_4: "RGASPI",
about_partner_5: "Yad Vashem",
about_partner_5: "Bişkek Devlet Üniversitesi",
about_partner_6: "Kırgız Cumhuriyeti Ulusal Arşivi",
about_stats_records: "Veritabanındaki kayıtlar",
about_stats_documents: "Veritabanındaki belgeler",
Expand Down
8 changes: 4 additions & 4 deletions front/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,9 @@
<!-- HERO / INTRO -->
<section class="hero">
<div class="hero-inner">
<div class="hero-card" id="heroFindCard" role="button" tabindex="0" aria-label="Найти человека">
<div class="hero-card-icon">&#128269;</div>
<h3 data-i18n="hero_find">Найти человека</h3>
<div class="hero-card" id="heroFindCard" role="button" tabindex="0" aria-label="Спросить у ИИ-ассистента">
<div class="hero-card-icon">&#129302;</div>
<h3 data-i18n="hero_find">Спросить у ИИ-ассистента</h3>
<p data-i18n="hero_find_desc">Введите имя или фамилию в строку поиска, чтобы найти информацию о жертве репрессий.</p>
</div>
<div class="hero-card" id="heroSuggestCard" role="button" tabindex="0" aria-label="Добавить сведения">
Expand Down Expand Up @@ -107,7 +107,7 @@ <h4 data-i18n="stats_title">Статистика</h4>

<!-- FOOTER -->
<footer class="site-footer">
<p data-i18n="footer_text">&copy; 2024 Архив Памяти. Открытая энциклопедия жертв политических репрессий.</p>
<p data-i18n="footer_text">&copy; 2026 Архив Памяти. Открытая энциклопедия жертв политических репрессий.</p>
</footer>

<script src="i18n.js"></script>
Expand Down
2 changes: 1 addition & 1 deletion front/list.html
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ <h4 data-i18n="stats_title">Статистика</h4>

<!-- FOOTER -->
<footer class="site-footer">
<p>&copy; 2024 Архив Памяти. Открытая энциклопедия жертв политических репрессий.</p>
<p>&copy; 2026 Архив Памяти. Открытая энциклопедия жертв политических репрессий.</p>
</footer>

<script src="i18n.js"></script>
Expand Down
2 changes: 1 addition & 1 deletion front/suggestions.html
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ <h3 data-i18n="suggestions_my">Мои предложения</h3>
</div>

<footer class="site-footer">
<p>&copy; 2024 Архив Памяти</p>
<p>&copy; 2026 Архив Памяти</p>
</footer>

<script src="i18n.js"></script>
Expand Down
17 changes: 15 additions & 2 deletions quick_test_ollama.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,19 @@

set -e

compose_exec() {
if docker compose version >/dev/null 2>&1; then
docker compose exec -T python_backend "$@"
return
fi
if command -v docker-compose >/dev/null 2>&1; then
docker-compose exec -T python_backend "$@"
Comment on lines +6 to +12
Copy link

Copilot AI Apr 4, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same issue as test_ollama.sh: using docker compose exec without ensuring the working directory contains the compose file makes this script fragile when invoked from outside the repo root. Consider changing into the repo root based on the script path (or passing -f).

Suggested change
compose_exec() {
if docker compose version >/dev/null 2>&1; then
docker compose exec -T python_backend "$@"
return
fi
if command -v docker-compose >/dev/null 2>&1; then
docker-compose exec -T python_backend "$@"
SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
compose_exec() {
if docker compose version >/dev/null 2>&1; then
(cd "$SCRIPT_DIR" && docker compose exec -T python_backend "$@")
return
fi
if command -v docker-compose >/dev/null 2>&1; then
(cd "$SCRIPT_DIR" && docker-compose exec -T python_backend "$@")

Copilot uses AI. Check for mistakes.
return
fi
echo " ❌ Docker Compose not found"
exit 1
}

echo "╔════════════════════════════════════════════════════════╗"
echo "║ ПРОВЕРКА ИНТЕГРАЦИИ OLLAMA С RAG ║"
echo "╚════════════════════════════════════════════════════════╝"
Expand Down Expand Up @@ -35,12 +48,12 @@ check

# 4. Конфигурация
echo "4️⃣ Проверка конфигурации backend..."
docker exec hackathon_python env | grep -q "RAG_LLM_PROVIDER=ollama"
compose_exec env | grep -q "RAG_LLM_PROVIDER=ollama"
check

# 5. RAG модули
echo "5️⃣ Проверка RAG модулей..."
docker exec hackathon_python python3 -c "from rag_engine import _build_llm, _build_embeddings; _build_llm(); _build_embeddings()" 2>&1 | grep -v "Warning" | grep -v "FutureWarning" | grep -v "Deprecation" > /dev/null
compose_exec python3 -c "from rag_engine import _build_llm, _build_embeddings; _build_llm(); _build_embeddings()" 2>&1 | grep -v "Warning" | grep -v "FutureWarning" | grep -v "Deprecation" > /dev/null
check

echo ""
Expand Down
Loading
Loading