Skip to content

Read and modify your files with the help of an AI assistant. (I use it to clean up my messy Downloads folder)

Notifications You must be signed in to change notification settings

curiousmq/file_assistant

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

File Assistant

Read and modify your files with the help of an AI assistant.

The program uses Local MCP server with Azure OpenAI API to interact with your files.

demo.mp4

Usage

> python main.py -h   
usage: fa [-h] {setup,start} ...

Read and modify your files with the help of an AI assistant.

options:
  -h, --help     show this help message and exit

commands:
  {setup,start}
    setup        Setup program variables
    start        Start the program

Example of listing files in the specified directory:

> python main.py start
Please specify the working directory: /your/folder/in/absolute/path
Working directory set to: '/your/folder/in/absolute/path'
Secure MCP Filesystem Server running on stdio
Allowed directories: [ '/your/folder/in/absolute/path' ]

(Say 'thank you' to exit)
Your message: list the file names in the current folder
AI response: In the current folder, the following files are present:

- 001_Favorite_Sports.txt
- 002_Books_about_AI.txt
- 003_How_to_Grow_Trees.txt

Installation

Requirements

  1. Python >= 3.12
  2. npx >= 10.2
  3. A model deployment on Azure OpenAI (or Azure AI Foundry)

Setup

Run the following command to setup your program:

> python main.py setup
Please provide the endpoint for your model: https://your-endpoint.cognitiveservices.azure.com/
Please provide the API version (default: '2024-12-01-preview'): 
Please provide the name of the deployment: gpt-4o-mini
Please provide your API key: 
Please provide the model name: gpt-4o-mini
Setup successfully!

Todos

  • Add OpenAI API support
  • Add conversation history when interacting with the assistant

About

Read and modify your files with the help of an AI assistant. (I use it to clean up my messy Downloads folder)

Topics

Resources

Stars

Watchers

Forks

Languages