Skip to content

Releases: kramcat/CharacterAI

Fix JSON, Auth, Images, Pydantic, New Docs

10 Apr 08:57
cf14ba6
Compare
Choose a tag to compare

The new version of the library has been completely rewritten and is close to stable release. Even though the version is alpha, you need to install it instead of 0.8.0

Your old code won't work, you need to re-read the documentation

Changes:

  • Adding authorization via mail and as a guest
  • Fix old bugs related to authorization by token and chat2
  • Added ability to download and upload pictures
  • Improved performance by switching to curl_cffi
  • Adding typing via Pydantic
  • Added new features: modify and pin character messages
  • Moved documentation to Sphinx Furo
  • PyAsyncCAI name changed to AioCAI

CHECK NEW DOCS AT DOCS.KRAM.CAT

Much faster, chat2, Fixes

05 Oct 20:51
b7d9e13
Compare
Choose a tag to compare

Changes:

  • There is no Playwright anymore, another library is used that does not load the system (!!!)
  • Added chat2 support (new chats with a different design)
  • Deleted client.upload_image()
  • Deleted client.start()
  • chat2 is only available in the asynchronous version
  • Fixes and improvements

Check out the documentation to find out how chat2 works

Managing Posts and Characters, Upload Images, Create Rooms

15 Aug 14:20
bfc16bd
Compare
Choose a tag to compare

Changes:

  • Small fixes by KubaPro010
  • Private variables
  • start() for PyCAI
  • Added plus for start()
  • Added timeout for start()
  • Added ping()
  • Added upload_image('PATH')
  • Added user.update('USERNAME')
  • Added the post class
    • post.get_post('POST_ID')
    • post.my_posts()
    • post.get_posts('USERNAME')
    • post.upvote('POST_ID')
    • post.undo_upvote('POST_ID')
    • post.send_comment('POST_ID', 'TEXT')
    • post.delete_comment('MESSAGE_ID', 'POST_ID')
    • post.create('HISTORY_ID', 'TITLE')
    • post.delete('POST_ID')
  • Added character.create(...)
  • Added character.update(...)
  • Added character.voices()
  • Added character.create_room('CHARACTERS', 'NAME', 'TOPIC')
  • Some fixes for parameters, check documentation
  • Some optimization
  • Added kwargs for functions

The library has a discord server!

If you have any questions/problems/suggestions or you just want to talk about AI and CharacterAI - welcome to my new Discord server

discord.gg/CZdQWzMV

Documentation, New Functions, Fixes

08 Jun 12:07
5fd0fb1
Compare
Choose a tag to compare

Changes:

  • Name of pyCAI changed to PyCAI
  • Name of pyAsyncCAI changed to PyAsyncCAI
  • Written documentation
  • Fix error 500
  • Added more errors
  • Added chat.rate('CHAR', RATE)
  • Added chat.next_message('CHAR')
  • Added chat.get_chat('CHAR')
  • Added chat.delete_message('HISTORY_ID', 'UUIDS_TO_DELETE')
  • Fixed showing filtered messages
  • Code changed to PEP8

POST methods, New chat.get_histories()

24 May 22:40
cd5dc74
Compare
Choose a tag to compare

List of changes

  • Now some functions work via POST requests, it's faster and more reliable
  • Fixed chat.new_chat()
  • chat.send_message() was rewritten
    • Instead of an error, it returns an error page
    • This function can show a message even if it is filtered
    • Fixed bugs with JSON
  • New chat.get_histories('CHAR')
    • This function returns all the stories with the character
  • Find users by nickname with user.info('NICKNAME')
    • This function returns information about the user

New chat.send_message(), Async, Fixes

16 May 20:42
55f4c5e
Compare
Choose a tag to compare

New Release! List of changes:

  • Add user.get_history in async
  • Fix chat.new_chat()
  • New chat.send_message()
  • New chat.get_history()
  • character.get_info() rename to character.info() and rewritten
  • Add character.search()
  • Add user.recent()
  • Fix small bugs

More detailed

Fix chat.new_chat()

This function has been rewritten and now returns a json response, and also gets a response faster than the site (thanks to HearYourWaifu)

Add character.search()

Now you can search for characters

character.search('TEXT')

Add user.recent()

Now you can view the latest chats

user.recent()

Fix Async

in previous versions, the asynchronous code was not finalized, now it is fully working

import asyncio
from characterai import pyAsyncCAI

async def main():
    client = pyAsyncCAI('TOKEN')
    await client.start(headless=True)

    while True:
        message = input('You: ')
        data = await client.chat.send_message('TOKEN', message, wait=True)
        print(f"{data['src_char']['participant']['name']}: {data['replies'][0]['text']}")

asyncio.run(main())

Fixed Functions, New Parameters

01 May 10:01
ffd9a6a
Compare
Choose a tag to compare

New Release! List of changes:

  • Fix broken functions
  • Remove user.get_history in async (I'll add in next version)
  • Add token parameter on all functions for custom token
  • Add wait parameter on all functions for waiting a responce when site is overloaded
  • Add headless parameter on pyCAI for browser (I don't know why, but suddenly you need)
  • Other changes (I don't remember which ones)