role.py 912 B

1234567891011121314151617
  1. # -*- coding: utf-8 -*-
  2. from .__load__ import *
  3. class Role(Model):
  4. __table__ = 'role'
  5. __comment__ = '角色表'
  6. id = Fields(type='int', primaryKey=True, autoIncrement=True, comment='ID')
  7. site_id = Fields(type='int', comment='所属站点')
  8. create_uid = Fields(type='int', comment='创建人ID', default='-1')
  9. owner_uid = Fields(type='int', comment='持有人ID', default='-1')
  10. name = Fields(type='varchar(500)', comment='名称')
  11. lang_model_id = Fields(type='int(11)', comment='模型ID', default='1')
  12. persona = Fields(type='text', comment='人设提示词', default='')
  13. use_num = Fields(type='int', comment='使用次数')
  14. status = Fields(type='tinyint', default='1', comment='角色状态:1是正常2是冻结')
  15. state = Fields(type='boolean', default='True', comment='数据存在状态')
  16. cdate = Fields(type='int', default='time', comment='创建时间')