deepakpant commited on
Commit
13904c3
·
1 Parent(s): c9db6ef

minor changes and version bump

Browse files
Files changed (5) hide show
  1. .env.example +1 -1
  2. Dockerfile +2 -0
  3. README.md +11 -8
  4. pyproject.toml +2 -2
  5. src/expressly_server/crew.py +2 -2
.env.example CHANGED
@@ -1,2 +1,2 @@
1
  MODEL=gemini/gemini-1.5-flash
2
- GEMINI_API_KEY=<gemini_api_key> # Your API key here
 
1
  MODEL=gemini/gemini-1.5-flash
2
+ MODEL_API_KEY=<model_api_key> # Your API key here
Dockerfile CHANGED
@@ -41,8 +41,10 @@ USER user
41
  # Copy the application code into the container
42
  COPY --chown=user . .
43
 
 
44
  EXPOSE 7860
45
 
 
46
  ENV GRADIO_SERVER_NAME="0.0.0.0"
47
 
48
  # Define the command to run your application
 
41
  # Copy the application code into the container
42
  COPY --chown=user . .
43
 
44
+ # Expose the port on which the application will run it's a default Gradio port.
45
  EXPOSE 7860
46
 
47
+ # Set the server name as 0.0.0.0 to access it from any host
48
  ENV GRADIO_SERVER_NAME="0.0.0.0"
49
 
50
  # Define the command to run your application
README.md CHANGED
@@ -32,9 +32,9 @@ The backend processes user inputs and generates formatted text tailored to the s
32
  ## Backend Configuration
33
 
34
  ### Prerequisites
35
- 1. Install `uv` if not already installed:
36
  ```bash
37
- pip install uv
38
  ```
39
  2. Navigate to your project directory and install dependencies:
40
  ```bash
@@ -46,13 +46,16 @@ The backend processes user inputs and generates formatted text tailored to the s
46
  1. Add environment variables to the `.env` file:
47
  ```plaintext
48
  MODEL=gemini/gemini-1.5-flash
49
- GEMINI_API_KEY=<gemini_api_key> # Your API key here
50
  ```
51
  2. Modify configuration files as needed:
52
- - `src/expressly_server/config/agents.yaml`: Define your agents.
53
- - `src/expressly_server/config/tasks.yaml`: Define your tasks.
54
- - `src/expressly_server/crew.py`: Add custom logic, tools, and arguments.
55
- - `src/expressly_server/main.py`: Customize inputs for agents and tasks.
 
 
 
56
 
57
  ### Running the Backend
58
  To start the backend server and execute tasks:
@@ -61,7 +64,7 @@ crewai run
61
  ```
62
 
63
  ## Additional Notes
64
- - Ensure all environment variables are correctly set in the `.env` file.
65
  - Regularly update your agents and tasks configuration to enhance functionality.
66
  - Refer to the CrewAI documentation for advanced customizations.
67
 
 
32
  ## Backend Configuration
33
 
34
  ### Prerequisites
35
+ 1. Install `uv` and `crewai` if not already installed:
36
  ```bash
37
+ pip install uv crewai
38
  ```
39
  2. Navigate to your project directory and install dependencies:
40
  ```bash
 
46
  1. Add environment variables to the `.env` file:
47
  ```plaintext
48
  MODEL=gemini/gemini-1.5-flash
49
+ MODEL_API_KEY=<model_api_key> # Your API key here
50
  ```
51
  2. Modify configuration files as needed:
52
+ - `src/expressly_server/config/agents.yaml`: Agents configuration.
53
+ - `src/expressly_server/config/tasks.yaml`: Tasks configuration.
54
+ - `src/expressly_server/crew.py`: Crew configuration with custom logic, tools, and arguments.
55
+ - `src/expressly_server/main.py`: Entrypoint to kick off the crew with inputs for agents and tasks.
56
+ - `src/expressly_server/app.py`: FastAPI configuration.
57
+ - `src/expressly_server/web_app.py`: Gradio configuration.
58
+
59
 
60
  ### Running the Backend
61
  To start the backend server and execute tasks:
 
64
  ```
65
 
66
  ## Additional Notes
67
+ - Ensure all environment variables are correctly set in the `.env` file check for [.env.example](.env.example) file for reference.
68
  - Regularly update your agents and tasks configuration to enhance functionality.
69
  - Refer to the CrewAI documentation for advanced customizations.
70
 
pyproject.toml CHANGED
@@ -1,7 +1,7 @@
1
  [project]
2
  name = "expressly_server"
3
- version = "0.1.0"
4
- description = "expressly-server using crewAI"
5
  authors = [{ name = "Deepak Pant", email = "deepak.93p@gmail.com" }]
6
  requires-python = ">=3.10,<=3.13"
7
  dependencies = [
 
1
  [project]
2
  name = "expressly_server"
3
+ version = "0.1.1"
4
+ description = "Expressly - Text Transformation App"
5
  authors = [{ name = "Deepak Pant", email = "deepak.93p@gmail.com" }]
6
  requires-python = ">=3.10,<=3.13"
7
  dependencies = [
src/expressly_server/crew.py CHANGED
@@ -10,7 +10,7 @@ from expressly_server.utils.utils import load_json_data, sanitize_input
10
 
11
  load_dotenv()
12
 
13
- GEMINI_API_KEY = os.getenv("GEMINI_API_KEY")
14
  MODEL = os.getenv("MODEL")
15
 
16
  FORMAT_JSON_FILE = "format.json"
@@ -32,7 +32,7 @@ class ExpresslyServer:
32
  agents_config = "config/agents.yaml"
33
  tasks_config = "config/tasks.yaml"
34
 
35
- llm = LLM(model=MODEL, api_key=GEMINI_API_KEY, temperature=0.7)
36
 
37
  @before_kickoff
38
  def validate_inputs(
 
10
 
11
  load_dotenv()
12
 
13
+ MODEL_API_KEY = os.getenv("MODEL_API_KEY")
14
  MODEL = os.getenv("MODEL")
15
 
16
  FORMAT_JSON_FILE = "format.json"
 
32
  agents_config = "config/agents.yaml"
33
  tasks_config = "config/tasks.yaml"
34
 
35
+ llm = LLM(model=MODEL, api_key=MODEL_API_KEY, temperature=0.7)
36
 
37
  @before_kickoff
38
  def validate_inputs(