[go: up one dir, main page]

CN107305446B - Method and device for acquiring keywords in pressure sensing area - Google Patents

Method and device for acquiring keywords in pressure sensing area Download PDF

Info

Publication number
CN107305446B
CN107305446B CN201610262713.4A CN201610262713A CN107305446B CN 107305446 B CN107305446 B CN 107305446B CN 201610262713 A CN201610262713 A CN 201610262713A CN 107305446 B CN107305446 B CN 107305446B
Authority
CN
China
Prior art keywords
phrase
phrases
pressure sensing
grammar
characters
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201610262713.4A
Other languages
Chinese (zh)
Other versions
CN107305446A (en
Inventor
李毅
李甜
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing ByteDance Network Technology Co Ltd
Original Assignee
Beijing ByteDance Network Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing ByteDance Network Technology Co Ltd filed Critical Beijing ByteDance Network Technology Co Ltd
Priority to CN201610262713.4A priority Critical patent/CN107305446B/en
Publication of CN107305446A publication Critical patent/CN107305446A/en
Application granted granted Critical
Publication of CN107305446B publication Critical patent/CN107305446B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/03Arrangements for converting the position or the displacement of a member into a coded form
    • G06F3/041Digitisers, e.g. for touch screens or touch pads, characterised by the transducing means
    • G06F3/0414Digitisers, e.g. for touch screens or touch pads, characterised by the transducing means using force sensing means to determine a position
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V30/00Character recognition; Recognising digital ink; Document-oriented image-based pattern recognition
    • G06V30/10Character recognition
    • G06V30/32Digital ink
    • G06V30/36Matching; Classification
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V30/00Character recognition; Recognising digital ink; Document-oriented image-based pattern recognition
    • G06V30/10Character recognition
    • G06V30/32Digital ink
    • G06V30/36Matching; Classification
    • G06V30/387Matching; Classification using human interaction, e.g. selection of the best displayed recognition candidate

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Multimedia (AREA)
  • General Engineering & Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Machine Translation (AREA)

Abstract

The invention discloses a method and a device for acquiring keywords in a pressure sensing area, wherein the method comprises the following steps: responding to external pressure sensed by the touch terminal, and acquiring a pressure sensing area; forming an enclosing area according to area boundary coordinates of the pressure sensing area; splitting recognizable characters in the pressure sensing area view into phrases or short sentences according to a preset rule; verifying whether the grammar of the split phrase or short sentence is complete, and if so, extracting the phrase or short sentence with complete grammar; and extracting and analyzing keywords in the pressure sensing area from phrases or phrases with complete grammar. The method and the device provided by the invention combine pressure induction, character recognition, intelligent analysis and keyword extraction, efficiently and quickly obtain the keywords in the pressure range, and improve the user interaction experience.

Description

Method and device for acquiring keywords in pressure sensing area
Technical Field
The invention relates to the technical field of man-machine interaction, in particular to a method and a device for acquiring keywords in a pressure sensing area.
Background
With the emergence and popularization of the pressure sensing (force touch) technology, more and more touch terminal devices such as smart phones and ipads start to support the pressure sensing technology.
In the pressure sensing technology, how to efficiently and quickly obtain keywords in a pressure sensing area range is a key technology for improving user interaction experience.
Disclosure of Invention
In view of this, the present invention provides a method and an apparatus for obtaining keywords in a pressure sensing area, so as to efficiently and quickly obtain keywords in a pressure range, thereby improving user interaction experience.
In order to achieve the purpose of the invention, the invention adopts the following technical scheme:
a method for acquiring keywords in a pressure sensing area comprises the following steps:
responding to external pressure sensed by the touch terminal, and acquiring a pressure sensing area;
geometrically constructing according to the regional boundary coordinates of the pressure sensing region to form an enclosing region;
splitting recognizable characters in the pressure sensing area view into phrases or short sentences according to a preset rule; the characters which can be identified in the pressure sensing area view are characters at least partially located in the surrounding area; the pressure sensing area view is determined according to the current display view of the touch terminal and the pressure sensing area;
verifying whether the grammar of the split phrase or short sentence is complete, and if so, extracting the phrase or short sentence with complete grammar;
and extracting and analyzing keywords in the pressure sensing area from phrases or phrases with complete grammar.
Optionally, the verifying whether the syntax of the split phrase or short sentence is complete further includes:
if not, carrying out extended retrieval on phrases or short sentences with incomplete grammars;
splicing characters obtained by expanding retrieval with expanded phrases or short sentences, and replacing the expanded phrases or short sentences with new phrases or short sentences formed after splicing;
and returning to the step of verifying whether the grammar of the split phrase or short sentence is complete until a new phrase or short sentence with complete grammar is expanded and retrieved, or until the first character or the last character on a straight line where the expanded phrase or short sentence is located is expanded, wherein the extension direction of the straight line is the character writing direction.
Optionally, the expanding and retrieving the phrase or phrase with incomplete grammar specifically includes:
when the first character of the phrase or the phrase with incomplete grammar is not at the head of the straight line where the phrase or the phrase is located, the first character of the phrase or the phrase with incomplete grammar is taken as an expansion starting point, the size of a character in the writing direction of the character is taken as an expansion value, and the phrase or the phrase with incomplete grammar is sequentially expanded against the writing direction of the character;
and when the tail word of the phrase or the phrase with the incomplete grammar is not at the last position of the straight line, expanding the phrase or the phrase with the incomplete grammar along the writing direction of the characters by taking the tail word of the phrase or the phrase with the incomplete grammar as an expansion starting point and taking the size of one character in the writing direction of the characters as an expansion value.
Optionally, the pressure sensing area view comprises recognizable characters on at least one straight line segment, and the extending direction of the straight line segment is the character writing direction; the method for splitting the recognizable characters in the pressure sensing area view into phrases or short sentences according to the preset rules specifically comprises the following steps:
and judging whether punctuation marks exist in the middle of the characters on each straight line segment one by one, if so, splitting the characters on the current straight line segment into a plurality of phrases or short sentences according to the punctuation marks.
Optionally, the determining whether punctuation marks exist in the text emphasis on each straight line segment one by one further includes:
if not, the characters on the current straight line segment are used as a phrase or short sentence.
Optionally, after extracting and analyzing the keywords in the pressure sensing area from the complete phrase or short sentence of the grammar, the method further includes:
and operating the extracted and analyzed keywords.
Optionally, the operations include searching, translating, and navigating.
An apparatus for obtaining keywords in a pressure sensing area, comprising:
the acquiring unit is used for responding to the external pressure sensed by the touch terminal and acquiring a pressure sensing area;
the geometric construction unit is used for performing geometric construction according to the regional boundary coordinates of the pressure sensing region to form an enclosed region;
the splitting unit is used for splitting the recognizable characters in the pressure sensing area view into phrases or short sentences according to a preset rule; the characters which can be identified in the pressure sensing area view are characters at least partially located in the surrounding area; the pressure sensing area view is determined according to the current display view of the touch terminal and the pressure sensing area;
the verification unit is used for verifying whether the grammar of the split phrase or short sentence is complete, and if so, extracting the phrase or short sentence with complete grammar;
and the extraction and analysis unit is used for extracting and analyzing the keywords in the pressure sensing area from the phrases or short sentences with complete grammars.
Optionally, the apparatus further comprises:
the extended search unit is used for performing extended search on phrases or short sentences with incomplete grammars when the result of the verification unit is negative; characters obtained through expanding retrieval are spliced with expanded phrases or short sentences, the expanded phrases or short sentences are replaced by new phrases or short sentences formed after splicing, the verification unit is triggered until new phrases or short sentences with complete grammars are expanded and retrieved, or until first characters or last characters on a straight line where the expanded phrases or short sentences are located are expanded, and the extending direction of the straight line is the character writing direction.
Optionally, the apparatus further comprises:
and the operation unit is used for operating the extracted and analyzed keywords.
Optionally, the pressure sensing area view comprises recognizable characters on at least one straight line segment, and the extending direction of the straight line segment is the character writing direction; the splitting unit includes:
the judging subunit is used for judging whether punctuation marks exist in the middle of the characters on each straight line segment one by one;
and the splitting subunit is used for splitting the characters on the current straight line segment into a plurality of phrases or short sentences according to the punctuation marks when the judgment result of the judging subunit is yes.
Optionally, the splitting unit further includes:
and the subunit is used for taking the characters on the current straight line segment as a phrase or short sentence when the judgment result of the judging subunit is negative.
Compared with the prior art, the invention has the following beneficial effects:
according to the technical scheme, the method for acquiring the keywords in the pressure sensing area, provided by the invention, comprises the steps of positioning the pressure sensing area through the pressure sensing technology, identifying the characters in the pressure sensing area view according to the size and coordinates of the characters in the pressure sensing area view, splitting the identified characters according to rules, carrying out grammar integrity verification on the split phrases and sentences, carrying out range expansion on incomplete phrases or sentences according to the rules until all the phrases or phrases can pass the grammar integrity verification, and finally carrying out keyword extraction analysis on the split phrases or phrases with complete grammar, so that the keywords in the pressure sensing area are obtained. Therefore, the method for acquiring the keywords in the pressure sensing area combines pressure sensing, character recognition, intelligent analysis and keyword extraction, efficiently and quickly acquires the keywords in the pressure range, and improves user interaction experience.
Drawings
In order that the detailed description of the invention may be clearly understood, reference will now be made to the accompanying drawings, which form a part hereof, and in which is shown by way of illustration specific embodiments in which the invention may be practiced. It is obvious that these drawings are only some embodiments of the invention, and that a person skilled in the art will be able to obtain further drawings without the inventive step.
Fig. 1 is a schematic flowchart of a method for obtaining keywords in a pressure sensing area according to an embodiment of the present invention;
fig. 2 is a schematic structural diagram of an apparatus for acquiring a keyword in a pressure sensing area according to an embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and technical effects of the present invention clearer and more complete, specific embodiments of the present invention will be described in detail below with reference to the accompanying drawings.
Before describing embodiments of the present invention, a number of technical terms related to the embodiments of the present invention will be described.
Force touch, pressure touch: when a touch terminal such as a mobile phone senses external pressure, the system can capture pressure information.
A data dictionary: is a directory of record databases and application metadata that a user can access.
Key words: and the words in a complete sentence or a partial sentence can embody the core semantics.
Fig. 1 is a flowchart illustrating a method for obtaining keywords in a pressure sensing area according to an embodiment of the present invention. As shown in fig. 1, the method comprises the steps of:
s101, responding to external pressure sensed by a touch terminal, and acquiring a pressure sensing area:
it should be noted that the acquired pressure sensing area includes area boundary coordinates thereof, and the area boundary coordinates are composed of X-axis coordinates and Y-axis coordinates. The zone boundary coordinates of the pressure sensing zone may be stored in a zone boundary sequence point list.
S102, performing geometric construction according to the region boundary coordinates of the pressure sensing region to form an enclosing region.
S103, splitting the recognizable characters in the pressure sensing area view into phrases or short sentences according to a preset rule:
in the embodiment of the invention, the view of the pressure sensing area is determined according to the current display view of the touch terminal and the pressure sensing area. The characters recognizable in the pressure sensing area view are characters at least partially located in the surrounding area.
As a specific embodiment of the present invention, whether the characters in the pressure sensing area view are recognizable or not may be determined by judging one by one whether part or all of the individual characters in the pressure sensing area view are located in the enclosing area or not according to the size of the characters, the coordinates of the characters, and the coordinates of the enclosing area in the pressure sensing area view. When part or all of a single character is located in the surrounding area, the character is determined to be recognizable, otherwise, the character is determined to be unrecognizable. In other words, as long as a part of one text is located within the enclosing region, it is determined that the text can be recognized.
It should be noted that the word size is the length and width of a pixel occupied by a single word.
In addition, in the embodiment of the present invention, the view of the pressure-sensitive area may include one or more recognizable texts on straight line segments, wherein the extending direction of the straight line segments is the writing direction of the texts. At this time, step S103 may specifically include the following steps:
s1031, judging whether punctuation marks exist in the middle of characters on each straight line segment one by one, if so, executing step S1032, otherwise, executing step S1033:
s1032, dividing the characters on the current straight line segment into a plurality of phrases or short sentences according to punctuation marks.
And S1033, taking the characters on the current straight line segment as a phrase or short sentence.
As another specific embodiment of the present invention, the characters located on one straight line segment may also be divided into one group, and in this case, whether punctuation marks exist in the middle of the characters on each straight line segment is determined one by one, that is, whether punctuation marks exist in the middle of the characters in each group is determined one by one.
Since the extending direction of the straight line segment is the writing direction of the characters in the embodiment of the present invention, when the writing direction of the characters is the line direction, the characters located on one straight line segment are divided into one group, which may specifically be: the recognized characters are grouped according to the row direction, and the characters in the same row are divided into the same group. Thus, the number of lines of text in the bounding region is divided into the number of groups.
When the writing direction of the text is the column direction, dividing the text on a straight line segment into a group, which may be specifically: the recognized characters are grouped according to the column direction, and the characters in the same column are divided into the same group. Thus, the number of columns of text in the bounding region is divided into the number of groups.
When the writing direction of the text is a diagonal direction, dividing the text on a straight line segment into a group may specifically be: characters which can be recognized are grouped according to the diagonal direction, and characters located on the same straight line segment are divided into the same group. In this way, the number of diagonal line segments in the bounding region divides the recognizable text into a number of groups.
It should be noted that, as a specific embodiment of the present invention, a first character string linked list may be set in the touch terminal, and the split phrases or short sentences (including the phrases or short sentences split according to punctuation marks and all the characters on a certain straight line segment if there is no punctuation mark on the straight line segment) may be stored in the first character string linked list.
S104, verifying whether the grammar of the split phrase or short sentence is complete, if so, executing a step S105, otherwise, executing a step S107:
the step may specifically be: and verifying whether the grammar of each phrase or short sentence is complete through an integrity verification function. Whether the grammar of the phrase or the short sentence is complete or not is to verify whether the phrase or the short sentence exists in a large data dictionary of the phrase or the short sentence in the background of the system, if so, the phrase or the short sentence is considered to be complete, at this time, step S105 is executed, if not, the phrase or the short sentence is considered to be incomplete, and at this time, step S107 is executed.
In the embodiment of the present invention, the integrity verification function is a double-parameter function, the double parameters may be a parameter 1 and a parameter 2, respectively, and the parameter 1 is a character string type parameter, in the embodiment of the present invention, the parameter 1 is a certain phrase or short sentence, the integrity verification function compares the parameter 1 with the phrase or short sentence in the big data dictionary of the phrase or short sentence in the system background, and determines whether the grammar of the phrase or short sentence in the parameter 1 is complete by determining whether the phrase or short sentence in the parameter 1 exists in the big data dictionary. When the syntax of the phrase or phrase in argument 1 is complete, then the integrity verification function returns a true. When the syntax of the phrase or phrase in argument 1 is incomplete, then the integrity verification function returns false.
The parameter 2 is an outgoing int type parameter, if the grammar is complete, 0 is returned, and if the grammar is incomplete and the first word of a phrase or a short sentence needs to be expanded, 1 is returned; if the grammar is incomplete and the tail words of the phrases or the short sentences need to be expanded, returning to step 2; if the grammar is incomplete and needs to expand both the first and last words of the phrase or phrase, return 3.
S105, extracting phrases or short sentences with complete grammar:
as a specific embodiment of the present invention, the extracted phrases or phrases with complete grammar can be stored in the second string linked list. When the split phrase or short sentence is originally stored in the first character string linked list, and when the phrase or short sentence with complete grammar is extracted from the first character string linked list and stored in the second character string linked list, the extracted phrase or short sentence with complete grammar can be deleted from the first character string linked list.
S106, extracting and analyzing keywords in the pressure sensing area from phrases or phrases with complete grammars:
the method comprises the following specific steps: and respectively comparing phrases or short sentences with complete grammar with keywords in the keyword data dictionary one by one, and extracting and analyzing the keywords in the pressure sensing area according to a matching algorithm.
This step may be implemented by executing a keyword extraction function. The keyword extraction function is a double-parameter function, the parameter 1 is an input character string type parameter, namely a certain phrase or short sentence in the second character string linked list, and the parameter 2 is a keyword linked list. And comparing the key word extraction function with the key words in the key word data dictionary through the parameter 1, and extracting and analyzing the key words of phrases or short sentences in the second character string linked list according to a matching algorithm so as to obtain the key words in the pressure sensing area.
As a specific embodiment of the present invention, a keyword chain table may be set on the touch terminal, and at this time, the extracted and analyzed keywords may be stored in the keyword chain table.
S107, carrying out extended retrieval on phrases or phrases with incomplete grammars, splicing characters obtained by the extended retrieval with extended phrases or phrases, replacing the extended phrases or phrases with new phrases or phrases formed after splicing, returning to the step S104, and carrying out the steps in a circulating manner until the extended retrieval obtains phrases or phrases with complete grammars or until the phrases or phrases are extended to the first characters or the last characters of the straight line where the extended phrases or phrases are located:
this step can be understood as: expanding and searching phrases or short sentences with incomplete grammars to obtain expanded characters, splicing the expanded characters and the expanded phrases or short sentences according to the character writing direction to form new phrases or short sentences, replacing the expanded phrases or short sentences with the new phrases or short sentences, returning to the step S104, namely verifying whether grammars of the new phrases or short sentences formed by splicing are complete, and circularly executing the steps until the expanded and searched phrases or short sentences with complete grammars are obtained or until the expanded phrases or short sentences are expanded to first characters or last characters of straight lines where the expanded phrases or short sentences are located.
In order to clearly understand the specific implementation manner of the invention for carrying out the extended search on the phrase or short sentence with incomplete grammar, the following takes the writing direction of the characters as the row direction, and the specific implementation manner is respectively introduced in two cases.
In the first case: when the first word of the phrase or short sentence with incomplete grammar is not at the head of the line where the phrase or short sentence is located:
as a specific embodiment of the present invention, step S107 may specifically be: and expanding the characters of the phrase or the short sentence with the incomplete grammar against the writing direction of the characters by taking the first character of the phrase or the short sentence with the incomplete grammar as an expansion starting point and the size of one character in the writing direction of the characters as an expansion value.
For example, one:
the phrase or short sentence with incomplete grammar consists of five words, ABCDE, and the writing direction of the words is the row direction and is written according to the sequence from left to right. Where "a" is the first word of the phrase or phrase. The line segment of "ABCDE" includes a word such as "… GFABCDE". When the 'A' is not at the head of the line where the straight line segment of the 'ABCDE' is located, the 'A' is used as an expansion starting point, the size of a character in the line direction is used as an expansion value, the 'ABCDE' is expanded against the character writing direction to obtain a diffusion retrieval character 'F', the character 'F' obtained through the expansion retrieval is spliced with an expanded phrase or short sentence 'ABCDE' to form a new phrase 'FABCDE', the new phrase 'FABCDE' is used for replacing the 'ABCDE' in the first character string linked list, and the steps S104 to S107 are returned to be executed.
When the grammar of the FABCDE is incomplete, the FABCDE is expanded to obtain an expanded search character G, the character G obtained by the expanded search is spliced with an expanded phrase or short sentence FABCDE to form a new phrase GFABCDE, the new phrase GFABCDE replaces the FABCDE in the first character string linked list, and the steps S104 to S107 are returned to. And the process is executed in a loop mode until a phrase or short sentence with complete grammar is obtained or until the expansion retrieves the first bit of the row of the ABCDE.
In the second case: when the tail word of the phrase or short sentence with incomplete grammar is not at the last bit of the line where the phrase or short sentence is located:
as another embodiment of the present invention, step S107 may also be specifically: and expanding the phrase or the short sentence with the incomplete grammar along the writing direction of the characters by taking the tail character of the phrase or the short sentence with the incomplete grammar as an expansion starting point and taking the size of one character in the writing direction of the characters as an expansion value.
Example two:
the phrase or phrase with incomplete grammar in the example one is still taken as an example for illustration. The writing direction of the characters is the row direction, and the characters are written according to the sequence from left to right. Wherein "E" is the end word of the phrase or phrase. The line on which the line of ABCDE belongs includes a word such as "… ABCDEFG …". When the 'E' is not at the last position of the line to which the straight line of the 'ABCDE' belongs, the 'ABCDE' is expanded by taking the 'E' as an expansion starting point and taking the size of a character in the line direction as an expansion value to obtain an expanded retrieval character 'F', the character 'F' obtained by the expanded retrieval is spliced with an expanded phrase or a short sentence 'ABCDE' to form a new phrase 'ABCDEF', the new phrase 'ABCDEF' is used for replacing the 'ABCDE' in the first character string linked list, and the steps S104 to S107 are returned to be executed.
When the grammar of the ABCDEF is incomplete, expanding the ABCDEF to obtain an expanded retrieval character G, splicing the character G obtained by the expanded retrieval with an expanded phrase or a short sentence ABCDEF to form a new phrase ABCDEFG, replacing the ABCDEF in the first character string linked list with the new phrase ABCDEFG, and returning to execute the steps S104 to S107. And the process is executed in a loop mode until a phrase or short sentence with complete grammar is obtained or until the expansion retrieves the last bit of the line where the ABCDE is located.
The first example and the second example are both described by taking the line direction as the writing direction of the characters. According to the example of expanding and searching phrases or phrases with incomplete grammars in the row direction, the skilled person can easily obtain a specific embodiment of expanding and searching phrases or phrases with incomplete grammars in the column direction or the diagonal direction or other writing directions.
Specifically, when expanding and searching phrases or short sentences with incomplete grammar in the column direction, expanding and searching the phrases or short sentences with incomplete grammar in the column direction according to the positions of the head and tail characters of the phrases or short sentences with incomplete grammar until new phrases or short sentences with complete grammar are expanded and searched, or until the first characters or the last characters of the columns where the expanded phrases or short sentences are located are expanded.
When expanding and retrieving phrases or phrases with incomplete grammar in the diagonal direction, expanding and retrieving the phrases or phrases with incomplete grammar in the diagonal direction according to the positions of the head and tail characters of the phrases or phrases with incomplete grammar until new phrases or phrases with complete grammar are expanded and retrieved or until the first characters or the last characters of the diagonal line where the expanded phrases or phrases are located are expanded and retrieved.
It should be noted that, when the first word of a phrase or a phrase with incomplete grammar is not at the head of the straight line where the phrase or the phrase is located and the last word of the straight line where the phrase or the phrase is located is not at the end of the straight line where the phrase or the phrase is located, the embodiment of the present invention may perform extended search on the first word and the last word of the phrase or the phrase according to the above-mentioned extended search for the first word and extended search for the last word, respectively, to obtain the phrase or the phrase with complete grammar. Furthermore, when the first word and the last word of the phrase or the phrase can be searched in an expanding manner, the embodiment of the present invention preferably performs the expanding search on the first word of the phrase or the phrase first word first, and when the phrase or the phrase with complete grammar cannot be obtained by the expanding search on the first word, performs the expanding search on the last word of the phrase or the phrase until the phrase or the phrase with complete grammar is obtained.
The keywords in the pressure sensing area can be obtained through the steps S101 to S107. The method for acquiring the keywords in the pressure sensing area comprises the steps of positioning the pressure sensing area through a pressure sensing technology, identifying characters in a view of the pressure sensing area according to the size and coordinates of the characters in the view of the pressure sensing area, splitting and grouping the identified characters according to rules, carrying out grammar integrity verification on grouped phrases and sentences, carrying out range expansion on incomplete phrases or sentences according to the rules until all the phrases or phrases can pass the grammar integrity verification, and finally carrying out keyword extraction analysis on the split phrases or phrases with complete grammar, so that the keywords in the pressure sensing area are acquired. Therefore, the method for acquiring the keywords in the pressure sensing area combines pressure sensing, character recognition, intelligent analysis and keyword extraction, efficiently and quickly acquires the keywords in the pressure range, and improves user interaction experience.
In addition, the obtained keywords can be used for operations of other purposes including but not limited to searching, translating and navigating, and thus, the keywords obtained by the method can provide interactive support for human-computer interaction.
In order to implement operations such as searching, translating, and navigating the obtained keyword, the method for obtaining the keyword in the pressure sensing area provided in the foregoing embodiment may further include the following step S108:
and S108, operating the extracted and analyzed keywords.
As a specific embodiment of the present invention, the operation includes, but is not limited to, a series of keyword follow-up operations such as searching, translating and navigating.
The search may support, but is not limited to, a native application name search, a native application content search, a native contact search, a native text message search, and a related internet online search. Which may specifically be implemented by calling a search function. The search function is a two-parameter function, wherein parameter 1 is an input string type parameter, i.e., a certain keyword in a keyword chain table, and parameter 2 is an enum type parameter, which represents the above mentioned and possibly used search modes in the following.
The translation may support, but is not limited to, invoking native existing translation software for translation or invoking an internet web page for translation.
The above is a specific implementation of the method for acquiring a keyword in a pressure sensing area according to the embodiment of the present invention. Based on the specific implementation mode, the invention further provides a specific implementation mode of the device for acquiring the keywords in the pressure sensing area. See in particular the examples below.
Fig. 2 is a schematic structural diagram of an apparatus for acquiring a keyword in a pressure sensing area according to an embodiment of the present invention. As shown in fig. 2, the apparatus includes the following units:
the acquiring unit 201 is configured to acquire a pressure sensing area in response to an external pressure sensed by the touch terminal;
a geometric construction unit 202, configured to perform geometric construction according to the region boundary coordinates of the pressure sensing region to form an enclosed region;
the splitting unit 203 is used for splitting the recognizable characters in the pressure sensing area view into phrases or short sentences according to a preset rule; the characters which can be identified in the pressure sensing area view are characters at least partially located in the surrounding area; the pressure sensing area view is determined according to the current display view of the touch terminal and the pressure sensing area;
a verification unit 204, configured to verify whether the grammar of the split phrase or short sentence is complete, and if so, extract the phrase or short sentence with complete grammar;
and the extraction and analysis unit 205 is used for extracting and analyzing the keywords in the pressure sensing area from the complete phrase or short sentence of the grammar.
As a specific embodiment of the present invention, the splitting unit 203 may specifically include:
the judging subunit is used for judging whether punctuation marks exist in the middle of the characters on each straight line segment one by one;
and the splitting subunit is used for splitting the characters on the current straight line segment into a plurality of phrases or short sentences according to the punctuation marks when the judgment result of the judging subunit is yes.
Further, the splitting unit may further include: and the subunit is used for taking the characters on the current straight line segment as a phrase or short sentence when the judgment result of the judging subunit is negative.
The foregoing is a basic structure of the apparatus for acquiring a keyword in a pressure sensing area according to the embodiment of the present invention. The device combines together forced induction, character recognition and characters split, and high-efficient swiftly obtains the keyword in the pressure range, has promoted user interaction experience.
In addition, in order to expand the phrases or phrases with incomplete grammars so that all the phrases or phrases in the surrounding area form phrases or phrases with complete grammars, the apparatus according to the above embodiment may further include:
an extended search unit 206, configured to perform extended search on phrases or short sentences with incomplete grammar when the result of the verification unit is negative; characters obtained through expanding retrieval are spliced with expanded phrases or short sentences, the expanded phrases or short sentences are replaced by new phrases or short sentences formed after splicing, the verification unit is triggered until new phrases or short sentences with complete grammars are expanded and retrieved, or until first characters or last characters on a straight line where the expanded phrases or short sentences are located are expanded, and the extending direction of the straight line is the character writing direction.
In addition, the obtained keywords can be used for operations of other purposes including but not limited to searching, translating and navigating, and thus, the keywords obtained by the device can provide interactive support for human-computer interaction.
In order to implement operations for other purposes on the acquired keywords, the apparatus provided in the foregoing embodiment may further include:
an operation unit 207, configured to operate on the extracted and analyzed keywords.
The previous description of the disclosed embodiments is provided to enable any person skilled in the art to make or use the present invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the invention. Thus, the present invention is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims (12)

1. A method for obtaining keywords in a pressure sensing area is characterized by comprising the following steps:
responding to external pressure sensed by the touch terminal, and acquiring a pressure sensing area;
geometrically constructing according to the region boundary coordinates of the pressure sensing region to form an enclosing region;
splitting recognizable characters in the pressure sensing area view into phrases or short sentences according to a preset rule; the characters which can be identified in the pressure sensing area view are characters at least partially located in the surrounding area; the pressure sensing area view is determined according to the current display view of the touch terminal and the pressure sensing area;
verifying whether the grammar of the split phrase or short sentence is complete, and if so, extracting the phrase or short sentence with complete grammar;
extracting and analyzing key words in the pressure sensing area from phrases or short sentences with complete grammar;
the verifying whether the grammar of the split phrase or short sentence is complete includes:
comparing the split phrases or short sentences with phrases or short sentences in a phrase or short sentence big data dictionary, and verifying whether the grammar of each phrase or short sentence is complete;
the method for extracting and analyzing the keywords in the pressure sensing area from the phrases or phrases with complete grammar comprises the following steps:
and respectively comparing the phrases or the short sentences with the keywords in the keyword data dictionary, and extracting and analyzing the keywords in the pressure sensing area according to a matching algorithm.
2. The method of claim 1, wherein the verifying whether the syntax of the split phrase or short sentence is complete further comprises:
if not, carrying out extended retrieval on phrases or short sentences with incomplete grammars;
splicing characters obtained by expanding retrieval with expanded phrases or short sentences, and replacing the expanded phrases or short sentences with new phrases or short sentences formed after splicing;
and returning to the step of verifying whether the grammar of the split phrase or short sentence is complete until a new phrase or short sentence with complete grammar is expanded and retrieved, or until the first character or the last character on a straight line where the expanded phrase or short sentence is located is expanded, wherein the extension direction of the straight line is the character writing direction.
3. The method according to claim 2, wherein the expanding search for phrases or phrases with incomplete grammar specifically includes:
when the first character of the phrase or the phrase with incomplete grammar is not at the head of the straight line where the phrase or the phrase is located, the first character of the phrase or the phrase with incomplete grammar is taken as an expansion starting point, the size of a character in the writing direction of the character is taken as an expansion value, and the phrase or the phrase with incomplete grammar is sequentially expanded against the writing direction of the character;
and when the tail word of the phrase or the phrase with the incomplete grammar is not at the last position of the straight line, expanding the phrase or the phrase with the incomplete grammar along the writing direction of the characters by taking the tail word of the phrase or the phrase with the incomplete grammar as an expansion starting point and taking the size of one character in the writing direction of the characters as an expansion value.
4. The method of claim 1, wherein the view of the pressure sensitive area comprises recognizable text on at least one straight line segment, and the extending direction of the straight line segment is a text writing direction; the method for splitting the recognizable characters in the pressure sensing area view into phrases or short sentences according to the preset rules specifically comprises the following steps:
and judging whether punctuation marks exist in the middle of the characters on each straight line segment one by one, if so, splitting the characters on the current straight line segment into a plurality of phrases or short sentences according to the punctuation marks.
5. The method of claim 4, wherein said determining whether punctuation marks exist in the text emphasis on each straight line segment one by one further comprises:
if not, the characters on the current straight line segment are used as a phrase or short sentence.
6. The method according to any one of claims 1-5, wherein after extracting the keywords in the pressure-sensitive region from the complete phrase or short sentence of the grammar, the method further comprises:
and operating the extracted and analyzed keywords.
7. The method of claim 6, wherein the operations comprise searching, translating, and navigating.
8. An apparatus for obtaining keywords in a pressure sensing area, comprising:
the acquiring unit is used for responding to the external pressure sensed by the touch terminal and acquiring a pressure sensing area;
the geometric construction unit is used for performing geometric construction according to the regional boundary coordinates of the pressure sensing region to form an enclosed region;
the splitting unit is used for splitting the recognizable characters in the pressure sensing area view into phrases or short sentences according to a preset rule; the characters which can be identified in the pressure sensing area view are characters at least partially located in the surrounding area; the pressure sensing area view is determined according to the current display view of the touch terminal and the pressure sensing area;
the verification unit is used for verifying whether the grammar of the split phrase or short sentence is complete, and if so, extracting the phrase or short sentence with complete grammar;
the extraction and analysis unit is used for extracting and analyzing keywords in the pressure sensing area from phrases or short sentences with complete grammars;
the verifying whether the grammar of the split phrase or short sentence is complete includes:
comparing the split phrases or short sentences with phrases or short sentences in a phrase or short sentence big data dictionary, and verifying whether the grammar of each phrase or short sentence is complete through an integrity verification function;
the method for extracting and analyzing the keywords in the pressure sensing area from the phrases or phrases with complete grammar comprises the following steps:
and respectively comparing the phrases or the short sentences with the keywords in the keyword data dictionary, and extracting and analyzing the keywords in the pressure sensing area according to a matching algorithm.
9. The apparatus of claim 8, further comprising:
the extended search unit is used for performing extended search on phrases or short sentences with incomplete grammars when the result of the verification unit is negative; characters obtained through expanding retrieval are spliced with expanded phrases or short sentences, the expanded phrases or short sentences are replaced by new phrases or short sentences formed after splicing, the verification unit is triggered until new phrases or short sentences with complete grammars are expanded and retrieved, or until first characters or last characters on a straight line where the expanded phrases or short sentences are located are expanded, and the extending direction of the straight line is the character writing direction.
10. The apparatus of claim 8 or 9, further comprising:
and the operation unit is used for operating the extracted and analyzed keywords.
11. The device of claim 8 or 9, wherein the pressure sensing area view comprises recognizable characters on at least one straight line segment, and the extending direction of the straight line segment is a character writing direction; the splitting unit includes:
the judging subunit is used for judging whether punctuation marks exist in the middle of the characters on each straight line segment one by one;
and the splitting subunit is used for splitting the characters on the current straight line segment into a plurality of phrases or short sentences according to the punctuation marks when the judgment result of the judging subunit is yes.
12. The apparatus of claim 11, wherein the splitting unit further comprises:
and the subunit is used for taking the characters on the current straight line segment as a phrase or short sentence when the judgment result of the judging subunit is negative.
CN201610262713.4A 2016-04-25 2016-04-25 Method and device for acquiring keywords in pressure sensing area Active CN107305446B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201610262713.4A CN107305446B (en) 2016-04-25 2016-04-25 Method and device for acquiring keywords in pressure sensing area

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610262713.4A CN107305446B (en) 2016-04-25 2016-04-25 Method and device for acquiring keywords in pressure sensing area

Publications (2)

Publication Number Publication Date
CN107305446A CN107305446A (en) 2017-10-31
CN107305446B true CN107305446B (en) 2020-08-14

Family

ID=60150421

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610262713.4A Active CN107305446B (en) 2016-04-25 2016-04-25 Method and device for acquiring keywords in pressure sensing area

Country Status (1)

Country Link
CN (1) CN107305446B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114983385B (en) * 2022-05-27 2023-03-10 北京四海汇智科技有限公司 System for providing intelligent nutrition management through human body composition detection

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101667251A (en) * 2008-09-05 2010-03-10 三星电子株式会社 OCR recognition method and device with auxiliary positioning function
CN103617159A (en) * 2012-12-07 2014-03-05 万继华 Method for translating natural languages into computer language, semantic analyzer and human-machine conversation system
CN104157171A (en) * 2014-08-13 2014-11-19 三星电子(中国)研发中心 Point-reading system and method thereof
CN104281394A (en) * 2013-07-05 2015-01-14 腾讯科技(深圳)有限公司 Method and device for intelligently selecting words
KR101480775B1 (en) * 2013-10-30 2015-01-22 전자부품연구원 Information display apparatus and method for vehicle using touch-pad, and information input module thereof

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN100550040C (en) * 2005-12-09 2009-10-14 佳能株式会社 Optical character recognition method and equipment and character recognition method and equipment
CN100541496C (en) * 2007-08-14 2009-09-16 新诺亚舟科技(深圳)有限公司 A method of combining search and learning for test questions realized on a personal handheld learning terminal
CN102999534A (en) * 2011-09-19 2013-03-27 北京金和软件股份有限公司 Chinese word segmentation algorithm based on reverse maximum matching
CN103093217A (en) * 2013-01-06 2013-05-08 北京百度网讯科技有限公司 Interactive image and character recognition method and device
CN104143093B (en) * 2013-05-10 2018-01-09 百度在线网络技术(北京)有限公司 Character recognition method and device
CN104503679B (en) * 2014-12-30 2017-04-12 北京奇虎科技有限公司 Searching method and searching device based on terminal interface touch operation

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101667251A (en) * 2008-09-05 2010-03-10 三星电子株式会社 OCR recognition method and device with auxiliary positioning function
CN103617159A (en) * 2012-12-07 2014-03-05 万继华 Method for translating natural languages into computer language, semantic analyzer and human-machine conversation system
CN104281394A (en) * 2013-07-05 2015-01-14 腾讯科技(深圳)有限公司 Method and device for intelligently selecting words
KR101480775B1 (en) * 2013-10-30 2015-01-22 전자부품연구원 Information display apparatus and method for vehicle using touch-pad, and information input module thereof
CN104157171A (en) * 2014-08-13 2014-11-19 三星电子(中国)研发中心 Point-reading system and method thereof

Also Published As

Publication number Publication date
CN107305446A (en) 2017-10-31

Similar Documents

Publication Publication Date Title
CN109635273B (en) Text keyword extraction method, device, equipment and storage medium
CN110770735B (en) Transcoding of documents with embedded mathematical expressions
EP2713255B1 (en) Method and electronic device for prompting character input
CN104462085B (en) Search key error correction method and device
WO2020056977A1 (en) Knowledge point pushing method and device, and computer readable storage medium
CN109917982B (en) Voice input method, device, equipment and readable storage medium
US10152540B2 (en) Linking thumbnail of image to web page
US20210374398A1 (en) Constructing a computer-implemented semantic document
KR20220111570A (en) The electronic device for processing the user's inquiry and the method for operating the same
CN112541109B (en) Answer abstract extraction method and device, electronic equipment, readable medium and product
CN108399157A (en) Dynamic abstracting method, server and the readable storage medium storing program for executing of entity and relation on attributes
US20140325350A1 (en) Target area estimation apparatus, method and program
CN109783612A (en) Report data localization method and device, storage medium, terminal
CN115203445B (en) Multimedia resource search method, device, equipment and medium
CN114792092B (en) Text theme extraction method and device based on semantic enhancement
CN119046553B (en) Method and device for realizing front-end keyword highlighting
CN119808752A (en) Document comparison and tracing method, device and computer storage medium
CN113419721B (en) Web-based expression editing method, device, equipment and storage medium
CN109344385B (en) Natural language processing method, apparatus, computer equipment and storage medium
CN107305446B (en) Method and device for acquiring keywords in pressure sensing area
CN110807322B (en) Method, device, server and storage medium for identifying new words based on information entropy
JP2002251402A (en) Method and device for document retrieval
CN115238044A (en) Sensitive word detection method, device and equipment and readable storage medium
CN111813897A (en) Article display method, article display device, server and storage medium
KR20190009061A (en) Word trademark search system and method for search service

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
TA01 Transfer of patent application right

Effective date of registration: 20190117

Address after: 100041 B-0035, 2 floor, 3 building, 30 Shixing street, Shijingshan District, Beijing.

Applicant after: BEIJING ZIJIE TIAODONG NETWORK TECHNOLOGY CO., LTD.

Address before: Room 309 and 310, Building 3, 33 D, 99 Kechuang 14th Street, Daxing Economic and Technological Development Zone, Beijing, 100176

Applicant before: Beijing hammer numeral science and technology company limited

TA01 Transfer of patent application right
GR01 Patent grant
GR01 Patent grant