Clipboard as a Bridge to AI Communication
ClipLLM is a project that explores using the clipboard as an interface for AI communication.
- Read and write data to the clipboard
- Communicate with AI models using clipboard data
- Easy-to-use Python interface
-
Clone the repository:
git clone https://github.com/pprp/ClipLLM.git cd ClipLLM -
Install dependencies:
pip install -r requirements.txt
Run the main script:
python src/main.pyFor detailed usage instructions, refer to the documentation.
We welcome contributions! Please see our Contributing Guide for more details.
ClipLLM is licensed under the MIT License. See the LICENSE file for details.
For questions or feedback, please open an issue on GitHub.
hdiutil detach /Volumes/ClipLLM\ Installer hdiutil convert ClipLLM.dmg -format UDRW -o ClipLLM_rw.dmg hdiutil attach ClipLLM_rw.dmg cp brain.iconset/icon_512x512.png /Volumes/ClipLLM\ Installer/.VolumeIcon.icns SetFile -a C /Volumes/ClipLLM\ Installer touch /Volumes/ClipLLM\ Installer
hdiutil detach /Volumes/ClipLLM\ Installer hdiutil convert ClipLLM_rw.dmg -format UDZO -o ClipLLM_final.dmg rm ClipLLM_rw.dmg -->
To create a DMG file for ClipLLM, follow these steps:
- Install required tools:
pip install pyinstaller py2app- Create a
setup.pyfile in your project directory:
from setuptools import setup
APP = ['interface.py']
DATA_FILES = []
OPTIONS = {
'argv_emulation': True,
'packages': ['PyQt5'],
'plist': {
'CFBundleName': 'ClipLLM',
'CFBundleDisplayName': 'ClipLLM',
'CFBundleGetInfoString': "Making ClipLLM",
'CFBundleIdentifier': "com.yourcompany.ClipLLM",
'CFBundleVersion': "0.1.0",
'CFBundleShortVersionString': "0.1.0",
'NSHumanReadableCopyright': u"Copyright © 2023, Your Company, All Rights Reserved"
}
}
setup(
app=APP,
data_files=DATA_FILES,
options={'py2app': OPTIONS},
setup_requires=['py2app'],
)- Build the application:
python setup.py py2app- Create a folder for the DMG contents:
mkdir ClipLLM-dmg
cp -R dist/ClipLLM.app ClipLLM-dmg/
ln -s /Applications ClipLLM-dmg/- Create the initial DMG:
hdiutil create -volname "ClipLLM Installer" -srcfolder ClipLLM-dmg -ov -format UDZO ClipLLM.dmg- To add a custom icon to the DMG:
# Convert icon to iconset if not already done
iconutil -c iconset brain.icns
# Convert DMG to read-write format
hdiutil convert ClipLLM.dmg -format UDRW -o ClipLLM_rw.dmg
# Mount the read-write DMG
hdiutil attach ClipLLM_rw.dmg
# Copy the icon and set attributes
cp brain.iconset/icon_512x512.png /Volumes/ClipLLM\ Installer/.VolumeIcon.icns
SetFile -a C /Volumes/ClipLLM\ Installer
touch /Volumes/ClipLLM\ Installer
# Unmount the DMG
hdiutil detach /Volumes/ClipLLM\ Installer
# Convert back to read-only format
hdiutil convert ClipLLM_rw.dmg -format UDZO -o ClipLLM_final.dmg
# Clean up
rm ClipLLM_rw.dmgYour final DMG file will be ClipLLM_final.dmg.
Note: Ensure you have the necessary permissions and sufficient disk space for these operations. If you encounter any issues, you may need to use sudo for some commands, but be cautious when doing so.