export interface export interface IResponseCode { type { string } memberof Code : string ; type { string } memberof DescriptionCN : string ; type { string } memberof DescriptionEN : string ; type { ( string | undefined ) } memberof Resolve : string | undefined ; } export interface export interface ICommonResponseBody { type { string } memberof code ? : string ; type { string | IISECompleteResult | IISEPlainResult } memberof data ? : string | IISECompleteResult | IISEPlainResult ; type { string } memberof desc ? : string ; type { string } memberof sid ? : string ; } export interface export interface ITTSResponseBody extends ICommonResponseBody { type { * } memberof audio ? : Buffer ; } export const ResponseCodes = [ { Code : "0" , DescriptionCN : "成功" , DescriptionEN : "success" , Resolve : undefined , } , { Code : "10105" , DescriptionCN : "没有权限" , DescriptionEN : "illegal access" , Resolve : "检查apiKey，ip，checkSum等授权参数是否正确" , } , { Code : "10106" , DescriptionCN : "无效参数" , DescriptionEN : "invalid parameter" , Resolve : "上传必要的参数， 检查参数格式以及编码" , } , { Code : "10107" , DescriptionCN : "非法参数值" , DescriptionEN : "illegal parameter" , Resolve : "检查参数值是否超过范围或不符合要求" , } , { Code : "10109" , DescriptionCN : "文本/音频长度非法" , DescriptionEN : "illegal text/audio length" , Resolve : "检查上传文本/音频长度是否超过限制" , } , { Code : "10110" , DescriptionCN : "无授权许可" , DescriptionEN : "no license" , Resolve : "提供请求的 appid、 auth_id 向服务商反馈" , } , { Code : "10114" , DescriptionCN : "超时" , DescriptionEN : "time out" , Resolve : "检测网络连接或联系服务商" , } , { Code : "10700" , DescriptionCN : "引擎错误" , DescriptionEN : "engine error" , Resolve : "提供接口返回值，向服务商反馈" , } , { Code : "11200" , DescriptionCN : "无发音人授权" , DescriptionEN : "no vcn auth" , Resolve : "确认是否具有使用该发音人权限，开通授权请联系讯飞工作人员" , } , { Code : "11201" , DescriptionCN : "成功" , DescriptionEN : "appid authorize number not enough" , Resolve : "服务单日调用次数超过限制	确认服务单日调用次数是否超过限制" , } , ] ; export interface export interface IISEPlainResult { type { IValue } memberof ret ? : IValue ; type { IValue } memberof total_score ? : IValue ; } export interface export interface IISECompleteResult { type { IISEResultMain } memberof read_sentence ? : IISEResultMain ; type { IISEResultMain } memberof read_chapter ? : IISEResultMain ; type { IISEResultMain } memberof read_word ? : IISEResultMain ; type { IISEResultMain } memberof read_syllable ? : IISEResultMain ; } export interface export interface IISEResultMain { type { string } memberof lan ? : string ; type { string } memberof type ? : string ; type { string } memberof version ? : string ; type { IRecPaper } memberof rec_paper ? : IRecPaper ; type { IRecPaper } memberof rec_tree ? : IRecPaper ; } export interface export interface IRecPaper { type { IISEResultSummary } memberof read_syllable ? : IISEResultSummary ; type { IISEResultSummary } memberof read_sentence ? : IISEResultSummary ; type { IISEResultSummary } memberof read_chapter ? : IISEResultSummary ; type { IISEResultSummary } memberof read_word ? : IISEResultSummary ; } export interface export interface IISECommonSection { type { string } memberof beg_pos ? : string ; type { string } memberof end_pos ? : string ; type { string } memberof content ? : string ; type { string } memberof time_len ? : string ; } export interface extends IISECommonSection export interface IISEResultSummary extends IISECommonSection { type { string } memberof total_score ? : string ; type { string } memberof phone_score ? : string ; type { string } memberof fluency_score ? : string ; type { string } memberof tone_score ? : string ; type { string } memberof integrity_score ? : string ; type { EXCEPT_INFO } memberof except_info ? : EXCEPT_INFO ; type { string } memberof is_rejected ? : string ; sentence ? : ISentence | ISentence [ ] ; type { string } memberof word_count ? : string ; type { string } memberof accuracy_score ? : string ; type { string } memberof standard_score ? : string ; } export interface extends IISECommonSection export interface ISentence extends IISECommonSection { type { string } memberof total_score ? : string ; type { string } memberof phone_score ? : string ; type { string } memberof fluency_score ? : string ; type { string } memberof tone_score ? : string ; type { ( IWord [ ] | IWord ) } memberof word ? : IWord [ ] | IWord ; type { string } memberof index ? : string ; type { string } memberof accuracy_score ? : string ; type { string } memberof standard_score ? : string ; type { string } memberof word_count ? : string ; } export interface extends IISECommonSection export interface IWord extends IISECommonSection { type { string } memberof symbol ? : string ; type { string } memberof global_index ? : string ; type { string } memberof index ? : string ; type { string } memberof property ? : string ; syll ? : ISyll [ ] | ISyll ; type { string } memberof total_score ? : string ; } export interface extends IISECommonSection export interface ISyll extends IISECommonSection { type { string } memberof symbol ? : string ; type { string } memberof rec_node_type ? : string ; type { DP_MESSAGE } memberof dp_message ? : DP_MESSAGE ; type { ( IPhone [ ] | IPhone ) } memberof phone ? : IPhone [ ] | IPhone ; type { string } memberof syll_accent ? : string ; type { string } memberof syll_score : string ; } export interface extends IISECommonSection export interface IPhone extends IISECommonSection { type { DP_MESSAGE } memberof dp_message ? : DP_MESSAGE ; type { string } memberof rec_node_type ? : string ; type { string } memberof is_yun ? : string ; type { string } memberof mono_tone ? : string ; } export interface IValue { value : string ; } export enum { number } export enum DP_MESSAGE { /**
     * 引擎认为该单元读了，但是不一定朗读正确
     */ Normal = "0" , /**
     * 漏读，该单元没有读
     */ Miss = "16" , /**
     * 增读，该单元是多度的文本内的内容
     */ Extra = "32" , /**
     * 回读，该单元是重复读的相邻文本的内容
     */ Repeat = "64" , /**
     * 替换，该单元读成了文本内其他的内容
     */ Replace = "128" } export enum { number } export enum EXCEPT_INFO { /**
     * 无异常
     */ Normal = "0" , /**
     * 无语音输入或者音量太小
     */ VolumeOutOfRange = "28673" , /**
     * 检测到语音为乱说类型
     */ Nonsense = "28676" , /**
     * 音频的信噪比太低
     */ LowSignalNoseRatio = "28680" , /**
     * 音频数据出现截幅
     */ AmpTruncated = "28690" }