Detailed Description
Conventional neural networks typically include an input layer, one or more hidden layers, and an output layer, where layers may be fully connected, but nodes between each layer are connectionless. This common neural network is powerless for many problems. For example, in speech recognition or natural language processing, it is generally necessary to base the prediction on the next word of a sentence, if it is desired to predict what the next word is. This is because the words before and after a sentence are not independent of each other.
In this case, a Recurrent Neural Network (RNN) arises. To process sequence data, the RNN correlates the current output of a sequence with the previous output. Thus, the network remembers the previous information and applies it to the calculation of the current output. In other words, the nodes between hidden layers are no longer connected but connected, and the input of a hidden layer includes not only the output of the input layer/previous hidden layer but also the output of the current hidden layer at the previous time.
Recurrent Neural Networks (RNNs) are most commonly used for time series data mining. Recurrent neural networks are a class of neural networks with memory and are therefore often used for mining of data with temporal correlation. In general, a neuron in a recurrent neural network can receive not only information from other neurons but also information of itself, thereby forming a cascaded network structure having loops.
Fig. 1 shows a diagram of an example simple Recurrent Neural Network (RNN) 100. As can be seen, the left part represents a simplified RNN structure, with the lowermost circle representing the input layer, the middle circle representing the hidden layer, and the uppermost circle representing the output layer. X in the input layer represents an input layer value vector. S in the hidden layer represents a hidden layer value vector. O in the output layer represents the output layer value vector. U, V and W each represent a weight matrix connecting the respective layers.
The functional relationship between the hidden layer value vector S and the input layer value vector X is shown in the following formula (1), for example:
St=f(U·Xt+W·St-1+b) (1)
as can be seen, the hidden layer value vector S at time ttNot only dependent on the current input layer value vector XtAnd a weight matrix U connecting the input layer and the hidden layer, the hidden layer value vector S also depending on the previous time t-1t-1And the corresponding weight matrix W (and possibly also the bias term b).
On the other hand, the output layer value vector O at time ttAnd a hidden layer value vector StFor example, the functional relationship of (2) is shown as follows:
Ot=g(V·St) (2)
as can be seen, the output tier value vector O at time ttDependent on the current hidden layer value vector StAnd a weight matrix V connecting the hidden layer and the output layer.
By spreading the RNN 100 in time, the structure of the right part of fig. 1 is obtained. As can be seen, the RNN adds a delay back to the hidden layer from the hidden layer compared to a fully connected structure such as a multi-layer perceptron (MLP), thereby giving the RNN a "memory" function. And is thus particularly suitable for processing time series data.
In theory, RNNs can process sequence data of any length. That is, the length of the input sequence may not be fixed. In practice, however, it is often assumed that the current state is only associated with a limited number of previous states for complexity reduction. RNNs and their various variants (e.g., bi-directional RNNs, LSTM, GRUs, etc.) have enjoyed great success and widespread use in numerous natural language processes.
RNNs can be classified into a variety of structures according to the number of input and output sequences, including: one-to-one structures, one-to-many structures, many-to-one structures, many-to-many structures, and the like. The many-to-many structure may also include structures where the input and output sequences are of equal length and structures where the input and output sequences are of unequal length. The many-to-many structure with unequal input and output sequences is called seq2seq (sequence-to-sequence) model. A common seq2seq model may include an encoder-decoder architecture, i.e., utilizing two RNNs, one RNN as an encoder and the other RNN as a decoder. According to one implementation, one word in the sequence may be input into the encoder at each time instant. The encoder is responsible for compressing the input sequence into a vector of specified length (i.e., embedding), which can be regarded as the semantics of the sequence, a process known as encoding. The decoder is responsible for generating the specified sequence from the semantic vector, a process known as decoding.
One of the ways that the encoder obtains the semantic vector may include directly taking the hidden state of the last input as the semantic vector C. Another way to obtain the semantic vector may include transforming the last hidden state to obtain the semantic vector C. The manner of obtaining the semantic vector may further include transforming all hidden states of the input sequence to obtain the semantic vector C. The decoder may input the semantic variables obtained by the encoder as initial states into the RNN as a decoder to obtain an output sequence. According to one exemplary implementation, the semantic vector C may participate in the operation only as an initial state. According to another exemplary implementation, the semantic vector C may participate in the operation of the sequence in the decoder at all time instants.
LSTM (long short term memory) networks are a special class of RNNs that are designed to address the above-mentioned issues with RNNs, among others. In general, an RNN may comprise a chain structure of repeating neural network element modules. In standard RNNs, this repeated unit block typically comprises only simple structures, such as a tanh layer. LSTM is also a chain structure, but the repeated unit modules have a more complex structure. Specifically, a general LSTM unit module may include an input gate, a forgetting gate, an output gate, and a cell, which interact in a special way, wherein the forgetting gate may be used to forget information that is not needed, the input gate and the output gate may be used for input and output of parameters, and the cell is used for storing states. LSTM also has various variations. The attention (attention) mechanism introduced in recent years can greatly improve the efficiency of the LSTM, thereby bringing a wider prospect for the LSTM.
Fig. 2 shows a diagram of an example LSTM network 200. LSTM network 200 may include a cascade of multiple cells. Each cell can obtain the output of the present stage by performing the embedding based on the output of the previous stage and the input of the present stage. Specifically, as can be seen, first, the current input may be cascaded with the previous h, noting the result as x. Then, x may be subjected to matrix point multiplication with the weight matrices w (f), w (i), w (j), w (o) to obtain result matrices f, i, j, o, respectively, where w (f), w (i), w (j), w (o) are the core weight parameters of the LSTM cells, and the purpose of training is to train the four weight matrix parameters. Then, sigmod operation is performed on matrix f, i.e. sigmod (f), sigmod operation is performed on matrix i, i.e. sigmod (i), tanh operation is performed on matrix j, i.e. tanh (j), sigmod operation is performed on matrix o, i.e. sigmod (o), and new c is calculated, wherein new c is old c sigmod (f) + (sigmod (i)) tanh (j). Finally, a new h is calculated, wherein new h is tanh (new c) sigmod (o). After the above operation, the cell is calculated to obtain a new c and a new h. Then h is taken as the output of the current time, and the binary group (c, h) is taken as the cell state of the current time to be stored for the next cell calculation.
One of the basic steps in the processing of natural language involves word segmentation. In the context of word-based languages such as English, spaces are used as natural delimiters between words. In scenarios such as chinese, only words, sentences and paragraphs can be simply delimited by distinct delimiters, without formally explicit delimiters between words. Therefore, when natural language processing of a Chinese is performed, word segmentation is generally required first. Existing word segmentation algorithms can be divided into three major categories: a word segmentation method based on character string matching, a word segmentation method based on understanding and a word segmentation method based on statistics. Whether the method is combined with the part-of-speech tagging process or not can be divided into a simple word segmentation method and an integrated method combining word segmentation and tagging.
FIG. 3 illustrates a word segmentation system 300 according to an exemplary aspect of the present disclosure. As can be seen, the word segmentation system 300 includes a word segmenter 301. When a sentence is input to the segmenter 301, the segmenter 301 outputs the segmented result. The tokenizer 301 may be implemented using any state-of-the-art or future-art tokenization algorithm.
For example, in a chinese word segmentation scenario, word segmentation methods based on string matching may be used, such as forward maximum matching, reverse maximum matching, least segmentation, and so on; an understanding-based word segmentation method; a statistical-based word segmentation method; rule-based word segmentation methods such as a minimum matching algorithm, a maximum matching algorithm, a word-by-word matching algorithm, a neural network word segmentation algorithm, an association-backtracking method, an N-shortest path word segmentation algorithm, and the like; an algorithm based on word frequency statistics, a word segmentation method based on expectation, a finite multi-level enumeration method and the like.
As can be seen, although one possible segmentation result is shown above, different segmentation results may be obtained in case different segmentation algorithms are used.
According to an exemplary embodiment, the source document may be input into the tokenizer sentence by sentence, and the tokenizer outputs the tokenized source sentence (or other unit) sentence by sentence or the tokenized source document in its entirety. According to another exemplary embodiment, the source document may be input integrally into the tokenizer, and the tokenizer may output the tokenized source document (or other element) sentence-by-sentence or integrally.
FIG. 4 illustrates a block diagram of a deep learning model 400 according to an exemplary aspect of the present disclosure. The deep learning model 400 may comprise, for example, a seq2seq model. According to an exemplary but non-limiting embodiment, the seq2seq model can comprise, for example, an encoder portion 410 and a decoder portion 420, wherein the encoder portion 410 can comprise a unit module h1,h2,……hn. Unit module h1,h2,……hnMay be implemented, for example, using the unit modules (spread out over time lines) discussed above in connection with RNNs (e.g., LSTM) and form the chain structure discussed above in connection with RNNs (e.g., LSTM) spread out over time lines. h is0May be a feature of the source script (or source style). Features may refer to categories, logos, genres, applicable demographics, etc. of paragraphs, examples of which may include, for example, the general body, the palace body, northeast, youth phrases, etc. … …. This will be further described below.
x1,x2,……xnIs a pair unit moduleh1,h2,……hnIs input. x is the number of1,x2,……xnMay include a sequence of words or phrases that may be obtained by tokenizing natural sentences in the source document. For example, the tokenization of natural sentences may be implemented using the tokenization system described above in connection with FIG. 2.
According to an exemplary but non-limiting embodiment, n can be a fixed window length. When the length of the natural sentence after word segmentation is less than n (for example, only x1,x2,……xiWherein i<n), the remaining portion may be filled with a blank (e.g., fill x)i+1,……xn). On the other hand, when the length of the natural sentence after word segmentation is larger than n, the sentence can be segmented. The segmentation criteria may include, for example, commas, discourse words, and/or other distinct segmented words, or the like, or any combination thereof.
According to an exemplary but nonlimiting embodiment, the unit module h1,h2,……hnWord/word sequence x based on this level input1,x2,……xnAnd the output of the preceding unit module is embedded to obtain the output vector h of the current stage1,h2,……hnWherein h is1,h2,……hn-1Are respectively input to the next unit module in the chain structure as its input.
Last unit module h which can be based on an encodernOutput of (i.e., hidden state) hnTo obtain a semantic vector C. For example, according to an exemplary but nonlimiting embodiment, h can be directly couplednAs semantic vector C. According to another exemplary but nonlimiting embodiment, h may be pairednA transformation is performed to obtain a semantic vector C. According to yet another exemplary but nonlimiting embodiment, the input sequence x may be input1,x2,……xnAll hidden states h of1,h2,……hnAggregated (and optionally transformed) to obtain a semantic vector C.
The decoder portion 420 may include a unit module h1’,h2’,……hm', where m can be greater than, equal to, or less than n. Unit module h1’,h2’,……hm' may be implemented, for example, using the unit modules discussed above in connection with RNNs (e.g., LSTMs), and form the chain structures discussed above in connection with RNNs (e.g., LSTMs).
According to an exemplary but nonlimiting embodiment, h0Is inputted to the unit module h1’,h0' may be a feature of the target manuscript (or target style), which may be different from the source manuscript feature. Examples of target script features may include, for example, a body in general, a body in palace, a word northeast, a word of youth, and so on … ….
According to an exemplary but non-limiting embodiment, the unit module h1’,h2’,……hm-1' the output vector h of the present stage can be obtained by embedding based on the semantic vector C and the output of the preceding stage unit module1’,h2’,……hm-1To the next unit module h2’,……hm'. In the example of fig. 4, a semantic vector C is input to each unit module h of the decoder 4201’,h2’,……hm-1'. In an alternative embodiment, the semantic vector C may also be input only to, for example, the first unit module of the decoder 420.
According to an exemplary but non-limiting embodiment, the unit module h1’,h2’,……hm' separately outputting y by embedding the output of the previous stage based on the semantic vector1,y2,……ym。y1,y2,……ymAnd may also include sequences of words or phrases. Combination y1,y2,……ymThe obtained sequence can be the natural sentence input sequence x with the source style1,x2,……xnAnd outputting the target natural sentence obtained after rewriting the characteristics of the target manuscript.
According to an exemplary but non-limiting embodiment, similarly, when the output sequence length is less than m (e.g., only y)1,y2,……yjWherein j is<m), the remaining portion of the output (e.g., y) may be usedj+1,……ym) May be filled with blanks. On the other hand, the sentence segmented at the encoder may be re-composed after being output at the decoder. The decoded sentences are combined in sequence to form the target document.
The various unit modules in the encoder 410 and decoder 420 may be implemented with various RNN structures, including, but not limited to, the network structures described above in connection with fig. 1 and 2, for example.
Although the embodiments are described in connection with outputting a target document corresponding to one target style, as can be appreciated, the present disclosure may encompass implementations in which multiple target documents corresponding to multiple target styles, respectively, are output simultaneously or sequentially.
By converting the content of the source style (e.g., sentence, paragraph, article) into the corresponding content of the target style (e.g., sentence, paragraph, article) through the encoder and decoder as described with reference to the exemplary embodiment of fig. 4, the rewrite flow of the deep learning assist can be realized, so that the work efficiency of manuscript rewrite can be greatly improved.
The training of the deep learning model may include, for example, offline training and online training. Fig. 5 illustrates a flow diagram of a method 500 of offline training of a deep-learning model (e.g., model 400 of fig. 4) according to an exemplary aspect of the present disclosure.
The method 500 may include setting up a feature library at block 502. As previously mentioned, features may refer to classification, identification, genre, applicable demographics, etc. of paragraphs, examples of which may include, for example, the common body, the palace body, northeast, youth words, etc. … …. Features may be represented by phrases or identifiers, etc. For example, according to an example, the natural sentence "this is good" may be characterized as a plain body. The corresponding palace body natural sentence is 'this is supposed to be excellent'. Setting the library of features may include, for example, setting different features according to different preferences for a population. The number of different article types that the model can adapt depends on the number of different features.
At block 504, the method 500 generates a library of document materials. The library of textual materials is associated with a particular feature. The document materials library of a specific feature may refer to a collection of documents having the specific feature. Generating a corpus of manuscript material associated with a particular feature may include, for example, grabbing all articles with the particular feature from a featured website (e.g., microblog, headline, banner, etc.). Generating a corpus of manuscript material associated with a particular feature may also include retrieving on a search engine using the feature to obtain articles with top-ranked relevance. Generating the manuscript material library associated with the specific feature may further include learning the marking model by using a machine learning method after obtaining certain article data through the foregoing various manners or any combination thereof, and then searching for more articles related to the feature in a text crawled on the web. According to an exemplary but non-limiting embodiment, learning the marking model can include learning a text classifier, which is then trained using the articles captured and/or acquired as described above as a training set. After training is finished, the trained text classifier can be used for searching for more articles related to corresponding features in the crawled text. After generating two or more document feature libraries associated with at least two or more of the feature types in the feature library, the method 500 may proceed to block 506.
At block 506, the method 500 trains a deep learning model, such as a seq2seq model or the like. According to an exemplary and non-limiting embodiment, training a deep learning model may include generating a training data set by finding pairs of two articles in each corpus of textual material that have the same or similar subject matter but different characteristics (e.g., classification, identification, genre, applicable population, etc. of paragraphs). The same or similar subject matter may include one or more of the following: contain the same keywords, and/or have sufficiently high similarity for each corresponding sentence in the article. The similarity may be calculated using various algorithms, including, but not limited to, for example, word vector-based similarity (e.g., cosine similarity, manhattan distance similarity, euclidean distance similarity, minuscule distance similarity, etc.), character-based similarity (e.g., edit distance similarity, simhash, number of common characters, etc.), probability statistics-based similarity (e.g., jackard similarity coefficient, etc.), word embedding model-based similarity (e.g., word2vec/doc2vec, etc.).
According to another exemplary but non-limiting embodiment, the training data set may also be obtained from other sources. For example, the training data set may be obtained directly from an external source. After the training data set is generated or obtained, a deep learning model, such as deep learning model 400 described with reference to fig. 4, may be trained using one article of each of two article pairs in the training data set as a source document and the other article as a target document. The above exemplary embodiments are trained on the granularity of articles, but the disclosure is not so limited. According to another exemplary but non-limiting embodiment, training may also be performed on sentences or other granularities.
Fig. 6 illustrates a block diagram of a method 600 of intelligent document rewrite using a trained deep learning model in accordance with an aspect of the present disclosure. The method 600 includes inputting a source document, a source style, and a target style, at block 602. The source style may represent a characteristic of the source document, including, for example, a category or style to which it belongs. The target style may represent a characteristic of the document to be rewritten, including, for example, a category or style to which it belongs. According to an exemplary but non-limiting embodiment, the source style may also be determined directly on the basis of the source document without further input.
At block 604, the method 600 includes outputting the target document with the trained deep learning model. For example, for the deep learning model described with reference to FIG. 4, the source document may be tokenized to x in natural sentences1,x2,……xn. The word segmentation may be implemented using, for example, the word segmentation system 300 described in conjunction with fig. 3. X after word segmentation1,x2,……xnUnit modules h that can be respectively inputted to the encoder 4101,h2,……hn. According to an exemplary and non-limiting embodiment, the length of a natural sentence after word segmentation is less than n (e.g., only x)1,x2,……xiWherein i<n), the remaining portion may be filled with a blank (e.g., fill x)i+1,……xn). On the other hand, when the length of the natural sentence after word segmentation is larger than n, the sentence can be segmented. The segmentation criteria may include, for example, commas, discourse words, and/or other distinct segmented words, or the like, or any combination thereof. Source style is input to h0. For example, sentence 1 in the source document is tokenized to x1,x2,……xn. Source style h0And the first word x1Is inputted to the first unit module h1. The first unit module is used for aligning a first word x1Embedding and outputting a vector h1. Vector h1With the second word x2Are inputted together to the second unit module h2. The second unit module h2For the second word x2Embedding and outputting a vector h2. Vector h2With a third word x3Are inputted together to the third unit module h3And so on. Vector hn-1With the nth word xnAre inputted together to the nth unit module hn. The nth unit module is used for the nth word xnEmbedding and outputting a vector hn. Through the unit modules h1,h2,……hnCascade between them, the word x of the sentence is established1,x2,……xnThe context relationship between them. As can be seen, although h is used for both the unit block and the vector of its outputnFormal expressions, but this is merely for the convenience of identifying their relatedness and their respective meanings are clear and should not be confused.
For the deep learning model described with reference to, for example, FIG. 4, it may be based on the last unit module h of the encodernOutput of (i.e., hidden state) hnTo obtain a semantic vector C. For example, according to an exemplary but nonlimiting embodiment, h can be directly couplednAs semantic vector C. According to another exemplary but nonlimiting embodiment, h may be pairednA transformation is performed to obtain a semantic vector C. According to yet another exemplary but nonlimiting embodiment, the input sequence x may be input1,x2,……xnAll hidden states h of1,h2,……hnPolymerized (and optionally modified)And) obtaining a semantic vector C. The semantic vector C may be input to each unit module h of the decoder portion 1201’,h2’,……hm', where m can be greater than, equal to, or less than n. h is0Is inputted to the unit module h1’,h0' may be a feature of the target manuscript (or target style), which may be different from the source manuscript feature. Unit module h1’,h2’,……hm-1' respective embedding of semantic vector C and output of vector h1’,h2’,……hm-1To the next unit module h2’,……hm'. Unit module h1’,h2’,……hm' also output y separately1,y2,……ym。y1,y2,……ymMay include a sequence of words or phrases. y is1,y2,……ymThe sequence of (2) can be a natural sentence input sequence x of the source style1,x2,……xnAnd outputting a sentence output sequence obtained by rewriting the target manuscript characteristics. According to an exemplary but non-limiting embodiment, similarly, when the output sequence length is less than m (e.g., only y)1,y2,……yjWherein j is<m), the remaining portion of the output (e.g., y) may be usedj+1,……ym) May be filled with blanks. On the other hand, the sentence segmented at the encoder may be re-composed after being output at the decoder.
At optional block 606, method 600 may include optionally making a human-assisted overwrite adjustment. The article manuscript automatically rewritten by the deep learning model may need to be checked and edited manually if the article manuscript meets the available standard. However, compared with pure manual rewriting, automatic rewriting of the deep learning model can greatly reduce the manual intervention degree and workload. For example, according to an exemplary but non-limiting embodiment, an editing interface can be provided to facilitate the addition, deletion, and/or modification of sentences in an edit box by a user. According to another exemplary but non-limiting embodiment, additions, deletions, and/or substitutions to paragraphs and/or sentences, etc. may also be supported. For example, the sentence may be manually input by the user at the time of addition, or may be automatically retrieved from the document material library. As another example, at the time of replacement, the user may manually input, or a sentence automatically generated by the deep learning model may be provided for selection.
At block 608, the method 600 may include outputting the result. Outputting the result may include, for example, outputting a rewritten sentence/article. After rewriting is completed, corresponding saving, previewing, auditing and/or publishing and the like can be performed.
Optional block 606 may also be omitted or changed in position. For example, the results may be output at block 608 and manually assisted, as appropriate or desired, for example, with a re-write adjustment.
FIG. 7 illustrates a diagram of a scenario 700 for intelligent document rewrite using a trained deep learning model, according to an exemplary aspect of the present disclosure.
As can be seen, the source document 701 is input into a participle module 702. The segmentation module 702 may, for example, include the segmentation system 300 described above in connection with fig. 3, and/or the like. The segmentation module 702 may output a segmented manuscript 703 based on the employed segmentation algorithm.
A tokenized script (e.g., a tokenized natural sentence or other unit) 703 is input into a trained deep learning model 704. The segmented manuscript 703 may be input into the deep learning model 704 sentence by sentence, or may be input into the deep learning model 704 by other units. For example, the tokenized script 703 may also be input into the deep learning model 704 in its entirety, or may be streamed into the deep learning model 704 while being generated.
A source style corresponding to the source document 701 and a target style corresponding to the target document may be input into the deep learning model 704. According to an alternative embodiment, the source style may also be automatically identified by the system from the source document. In this case, the system may also include, for example, a feature recognition module (not shown). For example, the source style may be a regular body and the target style may be a young language.
The deep learning model 704 may include, for example, the deep learning model 400 described above in connection with fig. 4, or variations thereof, and so forth. Based on the source style and the target style, the deep learning model 704 may rewrite the segmented source document 703 accordingly, for example, from a normal body to a body of a young person.
The deep learning model 704 outputs a target document 705 rewritten based on the target style. According to an exemplary embodiment, the target manuscript 705 may be output sentence by sentence, for example, a target sentence may be output every sentence of the source manuscript input, or a target sentence may be output sentence by sentence for the source manuscript input as a whole. According to another exemplary embodiment, the target manuscript 705 may be output in its entirety. For example, for a source document that is input in its entirety, all target sentences may be combined and output after they are obtained. For another example, for a source document input sentence by sentence, all target sentences may be obtained and then combined to output a target document. Combining the target sentences may include sequentially merging the target sentences to obtain the target document. The target document 705 may be output directly to the outside or may be output after being provided by the deep learning model 704 with further human-assisted overwrite adjustment.
FIG. 8 illustrates a block diagram of an offline training apparatus 800 for deep learning models, according to an exemplary aspect of the present disclosure. The deep learning model may include, for example, the deep learning model 400 described in conjunction with fig. 4, and the like.
According to an exemplary but non-limiting embodiment, the offline training device 800 of the deep learning model can include a module 802 for setting a feature library. The module for setting a feature library 802 may, for example, implement the functionality described above in connection with block 502 of fig. 5, and/or the like.
According to an exemplary but non-limiting embodiment, the offline training apparatus 800 of the deep learning model can further include a module 804 for generating a corpus of manuscript materials. The module 804 for generating a library of manuscript material may, for example, implement the functionality described above in connection with block 504 of fig. 5, and/or the like.
According to an exemplary but non-limiting embodiment, the offline training apparatus 800 for deep learning models can further include a module 806 for training the deep learning models. The module for training the deep learning model 806 may, for example, implement the functionality described above in connection with block 506 of fig. 5, and/or the like.
Fig. 9 illustrates a block diagram of an apparatus 900 for intelligent document rewrite using a trained deep learning model in accordance with an aspect of the disclosure.
According to an exemplary but non-limiting embodiment, intelligent document-rewriting device 900 may include a module 902 for inputting a document, a source style, and a target style. Module for inputting a manuscript, a source style, and a target style 902 may, for example, implement the functionality described above in connection with block 602 of fig. 6, and/or the like. Although direct input of the source style is described in the present embodiment, the source style may be extracted from the input source document according to an alternative embodiment.
According to an exemplary but non-limiting embodiment, intelligent document-rewriting device 900 may also include a module 904 for outputting the target document with the trained deep learning model. Module for outputting the target document with the trained deep learning model 904 may, for example, implement the functionality described above in connection with block 604 of fig. 6, and/or the like.
According to an exemplary but non-limiting embodiment, intelligent document rewrite apparatus 900 may also optionally include a module 906 for performing manually-assisted rewrite adjustments. Module for manually assisted overwrite adjustment 906 may, for example, implement the functionality described above in connection with block 606 of fig. 6, or the like.
According to an exemplary but non-limiting embodiment, intelligent document-rewriting device 900 may also include a module 908 for outputting results. The module for outputting results 908 may, for example, implement the functionality described above in connection with block 608 of fig. 6, and/or the like. The output result may be, for example, the target document or part thereof rewritten by the deep learning model, or may be the target document or part thereof adjusted by the manual-assisted rewriting.
Although the present application describes the intelligent document-rewriting method and apparatus based on deep learning by taking the seq2seq model as an example, the present application is not limited thereto, but can be applied to any deep learning model in the existing and future technologies.
Those of ordinary skill in the art appreciate that the benefits of the disclosure are not realized in full in any single embodiment. Various combinations, modifications, and alternatives will be apparent to one of ordinary skill in the art in light of this disclosure.
Furthermore, the term "or" is intended to mean an inclusive "or" rather than an exclusive "or". That is, unless specified otherwise or clear from context, the phrase "X" employing "a" or "B" is intended to mean any of the natural inclusive permutations. That is, the phrase "X" is satisfied using either "a" or "B" by any of the following examples: x is A; x is B; or X employs both A and B. The terms "connected" and "coupled" can mean the same thing, meaning that two devices are electrically connected. In addition, the articles "a" and "an" as used in this disclosure and the appended claims should generally be construed to mean "one or more" unless specified otherwise or clear from context to be directed to a singular form.
Various aspects or features will be presented in terms of systems that may include a number of devices, components, modules, and the like. It is to be understood and appreciated that the various systems may include additional devices, components, modules, etc. and/or may not include all of the devices, components, modules etc. discussed in connection with the figures. Combinations of these approaches may also be used.
The various illustrative logics, logical blocks, modules, and circuits described in connection with the embodiments disclosed herein may be implemented or performed with a general purpose processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field Programmable Gate Array (FPGA) or other programmable logic device, discrete gate or transistor logic, discrete hardware components, or any combination thereof designed to perform the functions described herein. A general purpose processor may be a microprocessor, but in the alternative, the processor may be any conventional processor, controller, microcontroller, or state machine. A processor may also be implemented as a combination of computing devices, e.g., a combination of a DSP and a microprocessor, a plurality of microprocessors, one or more microprocessors in conjunction with a DSP core, or any other such configuration. Further, at least one processor may comprise one or more modules operable to perform one or more of the steps and/or actions described above. For example, the embodiments described above in connection with the various methods may be implemented by a processor and a memory coupled to the processor, wherein the processor may be configured to perform any of the steps of any of the methods described above, or any combination thereof.
Further, the steps and/or actions of a method or algorithm described in connection with the aspects disclosed herein may be embodied directly in hardware, in a software module executed by a processor, or in a combination of the two. For example, the embodiments described above in connection with the various methods may be implemented by a computer readable medium having stored thereon computer program code which, when executed by a processor/computer, performs any of the steps of any of the methods described above, or any combination thereof.
All structural and functional equivalents to the elements of the various aspects described throughout this disclosure that are known or later come to be known to those of ordinary skill in the art are expressly incorporated herein by reference and are intended to be encompassed by the claims. Moreover, nothing disclosed herein is intended to be dedicated to the public regardless of whether such disclosure is explicitly recited in the claims.