chuckfinca commited on
Commit
1437923
·
1 Parent(s): 0031f83

chore(project): Initialize project for FOT Recommender

Browse files

- Renames the project from 'demo_application' to 'fot_intervention_recommender' to accurately reflect its purpose.
- Updates pyproject.toml with all necessary dependencies for the RAG system as defined in the implementation plan (langchain, faiss-cpu, pymupdf, etc.).
- Modifies the console script entry point in pyproject.toml to 'fot-recommender'.

This commit completes the environment setup described in Phase 0 of the plan, establishing the foundational scaffolding for development.

README.md CHANGED
@@ -4,18 +4,27 @@ A Python project for coding exercises and development.
4
 
5
  ## Setup for Development
6
 
7
- This is the standard setup for working on this project. It will install the application and all the necessary development tools (pytest, black, etc.).
8
-
9
- 1. **Create the virtual environment:**
10
- ```bash
11
- uv venv
12
- ```
13
-
14
- 2. **Install the project in editable mode with development dependencies:**
15
- ```bash
16
- uv pip install -e ".[dev]"
17
- ```
18
- This command installs the project, all development tools (like pytest and black), and creates the demo-app command-line script.
 
 
 
 
 
 
 
 
 
19
 
20
 
21
  ## Running the Application
 
4
 
5
  ## Setup for Development
6
 
7
+ This project has dependencies with specific hardware requirements (e.g., PyTorch). To ensure a smooth setup on any machine, follow this two-step process.
8
+
9
+ 1. **Create the virtual environment:**
10
+ ```bash
11
+ uv venv
12
+ ```
13
+
14
+ 2. **Install PyTorch Separately:**
15
+ This command lets PyTorch's installer find the correct version for your specific hardware (Intel Mac, Apple Silicon, Windows, Linux, etc.).
16
+ ```bash
17
+ uv pip install torch --index-url https://download.pytorch.org/whl/cpu
18
+ ```
19
+ *Note: We are explicitly using the CPU-only version of PyTorch, which is perfect for this project and avoids complex CUDA dependencies.*
20
+
21
+ 3. **Install the Project:**
22
+ Now that the difficult dependency is handled, install our application and its other development tools.
23
+ ```bash
24
+ uv pip install -e ".[dev]"
25
+ ```
26
+
27
+ This command will now see that a compatible version of `torch` is already installed and will proceed without errors.
28
 
29
 
30
  ## Running the Application
pyproject.toml CHANGED
@@ -3,17 +3,31 @@ requires = ["setuptools>=61.0", "wheel"]
3
  build-backend = "setuptools.build_meta"
4
 
5
  [project]
6
- name = "demo_application"
7
  version = "0.1.0"
8
- description = "Demo application for technical interview"
9
  readme = "README.md"
10
  requires-python = ">=3.12"
11
  dependencies = [
12
  "setuptools>=80.9.0",
 
 
 
 
 
 
 
 
 
 
 
 
 
 
13
  ]
14
 
15
  [project.scripts]
16
- demo-app = "demo_application.main:main"
17
 
18
  [project.optional-dependencies]
19
  dev = [
 
3
  build-backend = "setuptools.build_meta"
4
 
5
  [project]
6
+ name = "fot_intervention_recommender"
7
  version = "0.1.0"
8
+ description = "Freshman On-Track Intervention Recommender PoC"
9
  readme = "README.md"
10
  requires-python = ">=3.12"
11
  dependencies = [
12
  "setuptools>=80.9.0",
13
+
14
+ # Pinned to v2.2.2 because the PyTorch team dropped support for macOS on Intel (x86_64)
15
+ # in subsequent releases. This is the last official version with a pre-built wheel
16
+ # that is compatible with older Mac hardware.
17
+ # See GitHub issue: https://github.com/pytorch/pytorch/issues/114602
18
+ "torch==2.2.2",
19
+
20
+ "langchain",
21
+ "sentence-transformers",
22
+ "faiss-cpu",
23
+ "pandas",
24
+ "pymupdf",
25
+ "pdfplumber",
26
+ "transformers",
27
  ]
28
 
29
  [project.scripts]
30
+ fot-recommender = "fot_recommender.main:main"
31
 
32
  [project.optional-dependencies]
33
  dev = [
src/{demo_application → fot_recommender}/__init__.py RENAMED
File without changes
src/{demo_application → fot_recommender}/main.py RENAMED
@@ -1,5 +1,5 @@
1
  def main():
2
- print("Hello from demo application!")
3
 
4
 
5
  if __name__ == "__main__":
 
1
  def main():
2
+ print("Hello from fot intervention recommender!")
3
 
4
 
5
  if __name__ == "__main__":
uv.lock ADDED
The diff for this file is too large to render. See raw diff