{"id":22352029,"url":"https://github.com/simonamdev/maltese-ai-lawyer-experiment","last_synced_at":"2025-03-26T12:10:35.190Z","repository":{"id":238755503,"uuid":"795179434","full_name":"simonamdev/maltese-ai-lawyer-experiment","owner":"simonamdev","description":"Can we create a Maltese AI Lawyer? This is the code used for the 6th May 2024 GDG session about using LLMs and RAG to answer questions about Maltese legislation.","archived":false,"fork":false,"pushed_at":"2024-05-07T21:27:03.000Z","size":6673,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-01-31T13:15:23.861Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/simonamdev.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-05-02T18:30:16.000Z","updated_at":"2024-05-08T09:13:20.000Z","dependencies_parsed_at":"2024-05-07T23:37:45.769Z","dependency_job_id":null,"html_url":"https://github.com/simonamdev/maltese-ai-lawyer-experiment","commit_stats":null,"previous_names":["simonamdev/maltese-ai-lawyer-experiment"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/simonamdev%2Fmaltese-ai-lawyer-experiment","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/simonamdev%2Fmaltese-ai-lawyer-experiment/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/simonamdev%2Fmaltese-ai-lawyer-experiment/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/simonamdev%2Fmaltese-ai-lawyer-experiment/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/simonamdev","download_url":"https://codeload.github.com/simonamdev/maltese-ai-lawyer-experiment/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245650496,"owners_count":20650105,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-12-04T12:16:56.722Z","updated_at":"2025-03-26T12:10:35.168Z","avatar_url":"https://github.com/simonamdev.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# maltese-ai-lawyer-experiment\n\nCan we create a Maltese AI Lawyer? This is the code used for the 6th May 2024 GDG session about using LLMs and RAG to answer questions about Maltese legislation.\n\n# Required tech\n\n- Miniconda\n- Ollama: https://github.com/ollama/ollama\n\n# Setup\n\n- conda create -n mal\n- conda activate mal\n- conda install pip\n- pip install llama-index\n  (Note: llama-index was at 0.10.33 at time of writing)\n- pip install llama-index-core llama-index-readers-file llama-index-llms-ollama llama-index-embeddings-huggingface\n- ollama pull llama3:8b\n- ollama pull gemma:7b\n- ollama pull phi3:3.8b\n- python3 test_e2e.py\n\n# Persistence\n\nTest and visualise embeddings generated\n\n- pip install matplotlib\n- python test_generate_embeddings.py\n- python visualise_embeddings.py\n\n# Persistence for all PDFs\n\n- docker run --name redis-vecdb -d -p 6379:6379 -p 8001:8001 --volume ./redis_storage/:/data redis/redis-stack:latest\n- pip install llama-index-vector-stores-redis redis\n- python test_generate_embeddings.py\n- python generate_embeddings.py\n\n# Running the final result\n\n- Ensure the redis docker container from above is running\n- Ensure all embeddings have been generated\n- python lawyer.py\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsimonamdev%2Fmaltese-ai-lawyer-experiment","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsimonamdev%2Fmaltese-ai-lawyer-experiment","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsimonamdev%2Fmaltese-ai-lawyer-experiment/lists"}