Giter VIP home page Giter VIP logo

not-llama-fs's People

Contributors

drforse avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

not-llama-fs's Issues

KeyError: 'files'

Hi there,

Great work on the initiative and improvements on this project. It's perfect for what I need it for. However, I'm encountering an error, which I think might be because I'm using macOS. Please get back to me with your thoughts on this issue.


Preparing ../../res/httpswwwbaincom/RETRIEVED/2022 Carbon Credit Disclosure.pdf
Detected mime type: application/pdf
Preparing ../../res/httpswwwbaincom/RETRIEVED/Bain Brief Why The 5g Pessimists Are Wrong.pdf
Detected mime type: application/pdf
Preparing ../../res/httpswwwbaincom/RETRIEVED/Modello 231 External Eng 2023.pdf
Detected mime type: application/pdf
Preparing ../../res/httpswwwbaincom/RETRIEVED/Bain Brief Finding The Sustainable Advantage In Chemicals.pdf
Detected mime type: application/pdf
Preparing ../../res/httpswwwbaincom/RETRIEVED/Relatorio De Igualdade.pdf
Detected mime type: application/pdf
Producing
[]
{}
Traceback (most recent call last):
  File "<frozen runpy>", line 198, in _run_module_as_main
  File "<frozen runpy>", line 88, in _run_code
  File "/Users/dutch22/Documents/GitHub/Spider/Spider PDF /out/not-llama-fs/app/__main__.py", line 46, in <module>
    main()
  File "/Users/dutch22/Documents/GitHub/Spider/Spider PDF /out/not-llama-fs/app/__main__.py", line 40, in main
    demo(args.path, args.producer, args.text_model, args.image_model, args.apikey)
  File "/Users/dutch22/Documents/GitHub/Spider/Spider PDF /out/not-llama-fs/app/__init__.py", line 54, in demo
    tree = producer.produce()
           ^^^^^^^^^^^^^^^^^^
  File "/Users/dutch22/Documents/GitHub/Spider/Spider PDF /out/not-llama-fs/not_llama_fs/producers/ollama_producer.py", line 119, in produce
    for n, file in enumerate(llama_response_json["files"]):
                             ~~~~~~~~~~~~~~~~~~~^^^^^^^^^
KeyError: 'files'
dutch22@Hossams-Laptop not-llama-fs %

Feature: Support Adobe files

Description

I encountered an issue while attempting to process Adobe files (specifically PSD files) with not_llama_fs. The system currently does not support the image format and returns an error. To enhance the functionality and versatility of not_llama_fs, I request support for Adobe file formats, particularly Photoshop files (.psd).

Error Traceback

Preparing /Users/xain/Downloads/Untitled-3.psd
Detected mime type: image/vnd.adobe.photoshop
Traceback (most recent call last):
  File "<frozen runpy>", line 198, in _run_module_as_main
  File "<frozen runpy>", line 88, in _run_code
  File "/Users/xain/not-llama-fs/app/__main__.py", line 22, in <module>
    main()
  File "/Users/xain/not-llama-fs/app/__main__.py", line 16, in main
    demo(args.path, args.producer, args.apikey)
  File "/Users/xain/not-llama-fs/app/__init__.py", line 44, in demo
    producer.prepare_files("image")
  File "/Users/xain/not-llama-fs/not_llama_fs/producers/llama_producer.py", line 87, in prepare_files
    self.prepare_file(file)
  File "/Users/xain/not-llama-fs/not_llama_fs/producers/llama_producer.py", line 65, in prepare_file
    result = self.client.generate(
             ^^^^^^^^^^^^^^^^^^^^^
  File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/ollama/_client.py", line 126, in generate
    return self._request_stream(
           ^^^^^^^^^^^^^^^^^^^^^
  File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/ollama/_client.py", line 97, in _request_stream
    return self._stream(*args, **kwargs) if stream else self._request(*args, **kwargs).json()
                                                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/ollama/_client.py", line 73, in _request
    raise ResponseError(e.response.text, e.response.status_code) from None
ollama._types.ResponseError: unsupported image format

Steps to Reproduce

  • Attempt to process a Photoshop (.psd) file using not_llama_fs.

  • Observe the error traceback indicating unsupported image format.

Expected Behavior

The application should successfully process Adobe file formats, starting with Photoshop (.psd) files, without raising an unsupported image format error.

Environment

OS: macOS (version 12.7.5)
Python Version: 3.12
not_llama_fs Version: 0.1.0

Proposed Solution

Implement support for Adobe file formats in not_llama_fs, including but not limited to:

  • Photoshop files (.psd)
  • Illustrator files (.ai)

Additional Context

Supporting Adobe file formats will cater to a broader user base, including graphic designers, illustrators, and other creative professionals who frequently work with these file types.

Thank you for considering this feature request. I look forward to seeing this enhancement in future releases.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.