admin
2025-06-06 9cd825aea53fa5ba0cda1485464af027e27f0ce4
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
package tech.aiflowy.ai.entity.base;
 
import tech.aiflowy.common.entity.DateEntity;
import com.mybatisflex.annotation.Column;
import com.mybatisflex.annotation.Id;
import com.mybatisflex.annotation.KeyType;
import com.mybatisflex.core.handler.FastjsonTypeHandler;
 
import java.io.Serializable;
import java.math.BigInteger;
import java.util.Date;
import java.util.Map;
 
 
public class AiChatMessageBase extends DateEntity implements Serializable {
 
    private static final long serialVersionUID = 1L;
 
    @Id(keyType = KeyType.Generator, value = "snowFlakeId")
    private BigInteger id;
 
    private BigInteger topicId;
 
    private String role;
 
    private String content;
 
    private String image;
 
    private Integer promptTokens;
 
    private Integer completionTokens;
 
    private Integer totalTokens;
 
    private String tools;
 
    @Column(typeHandler = FastjsonTypeHandler.class)
    private Map<String, Object> options;
 
    private Date created;
 
    private Date modified;
 
    public BigInteger getId() {
        return id;
    }
 
    public void setId(BigInteger id) {
        this.id = id;
    }
 
    public BigInteger getTopicId() {
        return topicId;
    }
 
    public void setTopicId(BigInteger topicId) {
        this.topicId = topicId;
    }
 
    public String getRole() {
        return role;
    }
 
    public void setRole(String role) {
        this.role = role;
    }
 
    public String getContent() {
        return content;
    }
 
    public void setContent(String content) {
        this.content = content;
    }
 
    public String getImage() {
        return image;
    }
 
    public void setImage(String image) {
        this.image = image;
    }
 
    public Integer getPromptTokens() {
        return promptTokens;
    }
 
    public void setPromptTokens(Integer promptTokens) {
        this.promptTokens = promptTokens;
    }
 
    public Integer getCompletionTokens() {
        return completionTokens;
    }
 
    public void setCompletionTokens(Integer completionTokens) {
        this.completionTokens = completionTokens;
    }
 
    public Integer getTotalTokens() {
        return totalTokens;
    }
 
    public void setTotalTokens(Integer totalTokens) {
        this.totalTokens = totalTokens;
    }
 
    public String getTools() {
        return tools;
    }
 
    public void setTools(String tools) {
        this.tools = tools;
    }
 
    public Map<String, Object> getOptions() {
        return options;
    }
 
    public void setOptions(Map<String, Object> options) {
        this.options = options;
    }
 
    public Date getCreated() {
        return created;
    }
 
    public void setCreated(Date created) {
        this.created = created;
    }
 
    public Date getModified() {
        return modified;
    }
 
    public void setModified(Date modified) {
        this.modified = modified;
    }
 
}