Beacon Offline Agent is an offline AI assistant that uses curated Knowledge Packs to deliver trusted, local information.
Built for resilience, it runs fully on modest laptops with no internet dependency, ensuring that critical guidance remains available in disaster and low resource scenarios.
- π Introduction
- π₯ Hardware Requirements
- π Installation & Configuration
- β‘ Quick Start
- π³ File Tree
- π§ Knowledge Packs
- π€ Contributing
- βοΈ Acknowledgments
- πΎ Proof of Concept for Hackathon
- π License
When internet or electricity goes down, people lose access to the information they need most. Beacon Offline Agent was built to solve this. After Hurricanes Milton and Helene in 2024, parts of Florida had no internet for weeks. In Bihar, India, 53 percent of people still lack reliable internet access. GPT OSS 20B is exceptionally powerful and has tool calling capabilties, but without local context it risks hallucinating. It cannot know which shelters are open in Pinellas County, FL or what first aid steps are safe in rural Bihar, India.
Beacon closes that gap with curated Knowledge Packs. These are community made bundles of documents, images, and citations that ground the model in trusted local sources. Packs can include first aid guides, disaster steps, or shelter maps, and the system runs entirely offline on a modest laptop, remaining useful even in low resource or emergency settings.
This project is especially relevant for:
- Communities affected by disasters
- Rural regions with limited connectivity
- Humanitarian and relief organizations
- Educators or local leaders sharing essential guidance
- Travelers in remote or offline environments
Some sample conversations can be found under Beacon Media Assets Folder.
Beacon Offline Agent depends on running GPT-OSS 20B locally with Ollama.
This means it will only work on laptops or desktops that can run GPT-OSS.
At a minimum, your system should have:
- 16 GB RAM (required for GPT-OSS 20B with quantization)
- A modern CPU (runs slower without GPU support)
- (Recommended) A GPU with β₯16 GB VRAM for faster inference
Follow these steps to set up the project.
Download the project code from GitHub:
git clone https://github.com/KaartikDev/beacon-offline-agent.git
cd beacon-offline-agentIt is recommended to use a virtual environment to isolate dependencies.
Mac/Linux:
python3 -m venv venv
source venv/bin/activateWindows (PowerShell):
python -m venv venv
venv\Scripts\activateWhen activated, your terminal prompt should show (venv) at the beginning.
Update pip and install all required packages from requirements.txt:
pip install -r requirements.txtDownload and install Ollama for your operating system:
π Ollama Installation Guide
Verify the installation:
ollama --versionThis project requires:
- GPT-OSS 20B (main language model)
- Nomic-Embed-Text v1.5 (embedding model)
Download them with:
ollama pull gpt-oss:20b
ollama pull nomic-embed-text:v1.5This may take several minutes depending on your internet speed.
Follow these steps to launch the Beacon Offline Agent demo UI from the Jupyter notebook FinalBeaconAgent.ipynb, using your virtual environment kernel and a preloaded Knowledge Pack.
- Open the beacon-offline-agent folder in your IDE (VS Code, PyCharm, JupyterLab, etc.).
- Open FinalBeaconAgent.ipynb.
- If prompted for an interpreter, pick your projectβs venv.
In the notebook menu bar:
- Go to Kernel β Change kernel β Python (beacon-venv) (or select the venv name you created).
- If you didnβt register the kernel, choose the venvβs Python via Kernel β Change kernel and select the appropriate interpreter.
Tip: If you see import errors, youβre likely not using the venv. Switch the kernel and try again.
In the notebook menu bar:
- Click Kernel β Restart & Run All (or Run β Run All Cells).
- Wait for all cells to finish executing (youβll see a
*next to a cell while itβs running).
When prompted in the notebook, type exactly one of the following options into the input cell / prompt:
FLORIDAβ Pinellas County, Florida β Hurricane Response kpackINDIAβ Bihar, India β Support kpack
The notebook will initialize the selected pack (load FAISS indices, metadata, etc.).
At the end of the notebook logs youβll see lines similar to:
* Running on local URL: http://XXX.X.X.X:XXXX
* To create a public link, set `share=True` in `launch()`.
Open the local URL in your browser to use the app. If a different port is shown, use that one.
- If the page doesnβt load, verify the notebook finished running and that the URL/port match the printed output.
- If the port
7860is busy, the app may select another port automatically; use the URL printed by the notebook. - If you change packs, Restart & Run All again to reload with the new selection.
- Make sure Ollama is running and the models are downloaded:
ollama list
Simplfied knowledge pack file tree
first_aid_knowledge_pack_v3/
βββ first_aid_knowledge_pack_v3/
βββ manifest.yaml
βββ assets/
β βββ bleeding/
β β βββ pressure.png
β β βββ tourniquet.png
β βββ burns/
β β βββ cool_water.png
β β βββ cover.png
β βββ child-illness/fever.png
β βββ choking-cpr/
β β βββ hands_only_cpr.png
β β βββ heimlich.png
β βββ contacts/office.png
βββ core/
β βββ bleeding/hi_en/TEMP.md
β βββ burns/hi_en/TEMP.md
β βββ child-illness/hi_en/TEMP.md
β βββ choking-cpr/hi_en/TEMP.md
β βββ wild-animals/hi_en/TEMP.md
βββ vector_db/
β βββ text/
β β βββ embeddings.jsonl
β β βββ meta.json
β β βββ faiss_index/
β β βββ index.faiss
β β βββ index.pkl
β βββ images/
β βββ captions.jsonl
β βββ embeddings.jsonl
β βββ index.bin
β βββ meta.json
β βββ faiss_index/
β βββ index.faiss
β βββ index.pkl
Knowledge Packs are curated, domain-specific bundles of trusted, local information.
Instead of letting the LLM βmake things up,β Beacon answers by running RAG over these packs only.
Whatβs inside a pack
- Structured metadata (
manifest.yaml: name, version, locales, asset paths) - Curated sources (core docs, maps, infographics, local contacts)
- Citations & provenance (sources, licenses, hashes)
- Precomputed vector indices (FAISS + embeddings) for fast offline search
Agent flow (per query)
- Select the appropriate pack for the userβs question
- Retrieve relevant chunks via RAG from that pack only
- Compose an answer grounded in those chunks
- If insufficient evidence exists, respond βI donβt know.β
1) Pinellas County, Florida β Hurricane Response (Kpack)
- Scope: Evacuation/shelters, post-hurricane safety, potable water, insurance steps, local contacts
- Includes: Shelter maps, county guidance, Ready.gov/FEMA references, local numbers
- Try it: In the notebook prompt, type
FLORIDA
2) Bihar, India β Support (Kpack)
- Scope: First aid basics, water safety, clinic/administration contacts, rural safety tips
- Includes: Core first-aid docs, local overlays (clinics/administration), Hindi/English materials
- Try it: In the notebook prompt, type
INDIA
The notebook (
FinalBeaconAgent.ipynb) will initialize the selected pack and load its FAISS indices.
Preview our proof-of-concept site: Pack Hub (mock)
Buttons & behavior (planned):
- Preview β opens a details modal (Region, Domain, Locales, Size, Updated, Downloads, tags).
- Quick Download β one-click download of the pack
.zip. - Download (in modal) β same as Quick Download.
- Add to Device (in modal) β sends the pack to
./knowledge_packs/<pack-name>/on your machine (once local linking is enabled). - Download Selected β batch downloads multiple checked packs.
- Clear Selection β clears current selections.
- Browse Packs / Create Pack β browse catalog or start the pack creation flow.
- Search bar β search by name, region, domain, or tag.
- Filters β filter by Region and Locales; includes grid/list view toggle.
Current status: This is a UI proof-of-concept β installs from the website are not enabled yet.
Weβre excited to collaborateβespecially on creating high-quality Knowledge Packs that help real communities.
- Pick a scope: Choose one place Γ domain Γ scenario (e.g., βPinellas, FL β Post-Hurricane Responseβ).
- Curate trusted sources: FEMA/Ready.gov/WHO/Red Cross + local overlays (shelters, clinics, maps, contacts).
- Verify licensing & cite everything: Add source, license, and (if possible) hash in the pack manifest.
- Structure the pack folder:
manifest.yaml(name, version, date, locales, assets, citations, indices)assets/(pngs of images, maps, infographics)core/(PDF or Markdown files of human-readable guidance by topic/locale:en/,hi/, etc.)vector_db/(precomputed FAISS + embeddings)
- Build indices: Use
textVectorDBCreation.ipynb(and optionalimageCaptionVectorDB.ipynb) to generate embeddings + FAISS. - Follow conventions: lowercase/kebab-case folders (e.g.,
choking-cpr/), accurate paths, clear topics, version bumps. - Test locally: Change the path and load the pack in
FinalBeaconAgent.ipynb, run all cells, ask in-scope questions, and confirm βI donβt knowβ for out-of-scope. - Package & share: Zip the folder; users will place it under
./knowledge_packs/<pack-name>/. Include a short README and changelog.
If youβre interested in helping out or want to deploy Beacon in your community/organization, please contact:
ktejwani81@ucla.edu
mukundsk@uw.edu
Core team β Kaartik Tejwani & Mukund Senthil Kumar.
Community & sources β Weβre grateful for publicly available guidance, maps, and data from FEMA/Ready.gov, WHO, Red Cross/IFRC, and local agencies (e.g., Pinellas County Emergency Management & Fire District, Bihar state/district administration).
Open-source stack β This project stands on the shoulders of: GPT-OSS 20B (via Ollama), Whisper, Piper TTS, FastAPI, Gradio, LangChain, FAISS, Nomic-Embed, Python, and Jupyter.
Friends & family β Thank you for testing, feedback, and the moral support that kept us shipping.
OpenAI Hackathon β For the spark (and deadline!) that pushed us to build this idea.
- Identify one target community (rural or disaster-affected).
- Build two scoped Knowledge Packs (e.g., Bihar First Aid, Tampa Hurricane).
- Run fully offline on local hardware.
- Deliver a simple live demo + static website hub mock for packs.
- Sample Conversations can be found under Beacon Media Assets.
Apache License 2.0 β see LICENSE.
