US 7827315 B2
A method, computer program product, and data processing system for compressing and abbreviating text messages at a first text messaging device for transport and subsequent interpretation at a second text messaging device is disclosed. A user-defined message length reduction profile for producing human-readable compressed text is associated with a source text message at a first text messaging device. The source text message is then shortened using abbreviations and transformation rules in the profile. The shortened text message can then be transmitted to a second text messaging device. In addition, the compression provided by the present invention, although intended to be human-readable, can be complemented with decompression software to expand the compressed and abbreviated text to its full length and verifying, using a checksum or other error detecting code, that the expanded version corresponds to the original text.
1. A computer program product in a non-transitory computer-readable medium for text based messaging using user defined abbreviations, the computer program product comprising functional descriptive material that, when executed by a computer, enables the computer to perform acts including:
associating, at a first text messaging device, a message length reduction profile with a source text message;
shortening the source text message only to the extent needed for the source text message to fit within a maximum message length constraint in accordance with the message length reduction profile to obtain a shortened text message;
compressing the message length reduction profile;
transmitting to a second text messaging device the message length reduction profile as compressed;
transmitting to the second messaging device information that denotes a correspondence between the message length reduction profile and the shortened text message; and
transmitting the shortened text message to the second text messaging device.
2. The computer program product of
3. The computer program product of
4. The computer program product of
5. The computer program product of
6. The computer program product of
7. The computer program product of
8. The computer program product of
9. The computer program product of
10. The computer program product of
11. The computer program product of
12. The computer program product of
13. A computer program product in a non-transitory computer-readable medium, the computer program product comprising functional descriptive material that, when executed by a computer, enables the computer to perform acts including:
receiving a shortened text message that is a shortened version of a source text message only to the extent needed for the source text message to fit within a maximum message length constraint in accordance with the message length reduction profile, wherein at least a portion of the shortened text message includes reduced character set text in which only a subset of a character set associated with the source text message is used;
receiving the message length reduction profile associated with the shortened text message, wherein the message length reduction profile is compressed;
receiving a first error-detecting code associated with the shortened text message;
retrieving a set of full-length text strings corresponding to the reduced character set text;
selecting a full-length text string from the set of full-length text string, wherein the full-length text string is selected on the basis of the full-length text string being a likely expansion of the reduced character set text;
expanding the shortened text message using the full-length text string to obtain an expanded text message;
calculating a second error-detecting code from the expanded text message; and
comparing the first error-detecting code with the second error-detecting code to determine whether the full-length text string is a proper expansion of the reduced character set text.
14. The computer program product of
in response to a determination that the full-length text string is not a proper expansion of the reduced character set text, performing a set of actions that includes:
selecting a second full-length text string from the set of full-length text strings; and
expanding the shortened text message using the second full-length text string.
This application is a divisional of application Ser. No. 10/324,516, filed Dec. 19, 2002, now U.S. Pat. No. 7,315,902 status allowed.
1. Technical Field
The present invention relates generally to the preparation of text messages for transmission between devices. In particular, the present invention is directed toward the preparation of human-readable compressed versions of text messages.
2. Description of Related Art
Text messaging devices, such as two-way alphanumeric pagers, text-enabled mobile telephone, wireless portable digital assistants (PDAs), computers operating instant messaging software, and other like devices allow users to transmit short text messages to other messaging device users. Generally, the size of text messages that may be transmitted is limited to some pre-determined level.
Lossless digital data compression techniques, such as Huffman codes or Lempel-Ziv compression, can sometimes reduce the length of a text message, but require that the recipient of the message be capable of decoding the compressed data, as conventional compression renders a text message unreadable to humans. It should also be noted that because of necessary overhead associated with conventional compression algorithms, conventional lossless compression algorithms tend to be less useful for smaller messages.
Abbreviations, shorthand, and other human-readable forms of text shortening have been used for centuries to save time or writing space. Acronyms and abbreviations such as PERL (Practical Extraction and Reporting Language) and UML (Uniform Modeling Language) are especially prevalent in the computing arts, for example. The elimination of vowels is another known technique for reducing the length of text in a human-readable fashion. For example, SPEEDWRITING is a trademark for a form of shorthand in which short vowels are generally eliminated from words. The written Hebrew language actually dispenses with vowels altogether, as the Hebrew alphabet consists of only consonants. Words that convey little meaning, such as “the” are often eliminated from newspaper headlines, telegrams, and other media where space is at a premium (e.g., “Dog bites man,” rather than “A dog bit a man”).
Computer technology has been applied to the problem of shortening text in a human-readable way. U.S. Pat. No. 6,279,018 to Kudrolli et al. describes a system for abbreviating and compacting text to cope with display space constraints in computer software. Kudrolli et al. describe using a computer algorithm to abbreviate words and phrases in text according to a user-defined dictionary of abbreviations. Kudrolli et al. also describe applying compressive transformations to text, such as eliminating vowels and whitespace to further reduce the size of the text to a level that fits within length constraints.
The algorithmic compression and abbreviation provided by Kudrolli et al., however, is adapted for use by a single user specifying rules for displaying text on that user's display. The Kudrolli et al. reference is not directed toward shortening text messages for transport and subsequent interpretation by a recipient. What is needed, therefore, is a compression and abbreviation scheme that is adapted for use in shortening text messages for transport to a second text messaging device associated with a second user.
The present invention provides a method, computer program product, and data processing system for compressing and abbreviating text messages at a first text messaging device for transport and subsequent interpretation at a second text messaging device. A message length reduction profile containing a dictionary of abbreviations and selected compressive transformation rules is associated with a source text message at a first text messaging device. The source text message is then shortened using the abbreviations and transformation rules in the profile. The shortened text message can then be transmitted to a second text messaging device. The profile can be selected from a plurality of profiles based on the intended recipient, so that the text message is shortened according to the intended recipient's preferences. Alternatively, the profile or a portion thereof may be transmitted to the second text messaging device so as to aid the second text messaging device or its user in interpreting the shortened text message.
In addition, the compression provided by the present invention, although intended to be human-readable, can be complemented with decompression software to expand the compressed and abbreviated text to its full length version by attempting to reverse the compressive transformations made to the text and verifying, using a checksum or other error detecting code, that the expanded version corresponds to the original text.
The novel features believed characteristic of the invention are set forth in the appended claims. The invention itself, however, as well as a preferred mode of use, further objectives and advantages thereof, will best be understood by reference to the following detailed description of an illustrative embodiment when read in conjunction with the accompanying drawings, wherein:
Portable messaging device 100 operates by executing programs stored in main memory 104 using processor 102. In addition, the portable messaging device 100 includes messaging application software stored in application memory 112. This application may be executed by the portable digital device 100 to perform various functions related to sending text messages via the wireless communication adapter 110 and transceiver 122. Wireless communication adapter 110 and transceiver 122 are used to send and receive data messages via a wireless communication link to another messaging device, generally relayed through some form of base station or repeater.
The present invention is directed toward the compression and abbreviation of a source text message at a first messaging device into a shortened text message for transmission to and subsequent interpretation at a second messaging device.
Messaging device 202 transmits shortened text message 204 and message length reduction profile 206 to a second messaging device 208. Messaging device 208 may then use message length reduction profile 206 to expand abbreviations into their full-length text meanings and/or reverse the effects of any compressive transformation rules applied to text message 204 to yield at least an approximation to the original message.
In an alternative embodiment, message length reduction profile 206 may be known ahead-of-time by both messaging device 202 and messaging device 208. For example, the user of messaging device 208 may have defined a profile that that user shares with a user of messaging device 202, or alternatively, the profile may be made available for download from a server or other form of public repository. In either case, messaging device 202 will know to use the profile defined by the user of messaging device 208 whenever transmitting text messages to messaging device 208. In such circumstances, transmission of message length reduction profile 206 from messaging device 202 to messaging device 208 can be avoided.
A personal dictionary of abbreviations may be implemented in the form of an associative array, as is shown in a Perl-like pseudocode in
Returning now to
It should also be noted that when a compressive transformation rule utilizing a reduced character set is used in conjunction with abbreviations or acronyms that may contain characters not found in the reduced character set, it is important that the application of the reduced character set compressive transformation rule does not interfere with the use of abbreviations. For example, if a compressive transformation rule to eliminate vowels is used in conjunction with abbreviations and acronyms that contain vowels, such as “FYI,” it is important that the vowels in the abbreviation or acronym are not eliminated by the compressive transformation rule (e.g., it is important that “FYI” not be compressed to “FY” for proper understanding of the message). This can be prevented in a number of ways. One possible technique that can be used is to apply the reduced character set rule first, then apply abbreviations whose “full length” text is actually a reduced character set representation of the true full length text.
Turning now to
Other examples of compressive transformation rules include converting words that represent numbers into numerals, eliminating whitespace, eliminating whitespace while capitalizing the first letter of each word, elimination of less valuable words or phrases, and elimination of words that would be understood according to context (e.g., “She is taller than I am,” can be written as “She is taller than I”, with no loss of meaning.).
An additional example of a compressive transformation rule would be to take very commonly used words and replace them with single characters or single character prefixes. Some possible substitutions that can be used while still preserving readability (in the [substitution/original] notation described above) —include, but are not limited to: [T/the], [O/of], [&/and], [2/to], [a/a] (assuming whitespace is eliminated, e.g., [adog/a dog]), and [N/in]. For example, the phrase “the dog” could be replaced with “Tdog” at a savings of four characters.
Although exhaustive application of abbreviation rules 304 and compressive transformation rules 310 may result in an optimally shortened text message, one of ordinary skill in the art will recognize that such rules may also be applied to a limited degree to achieve a less optimally, but adequately shortened text message. For example, in a preferred embodiment of the present invention, abbreviation rules 304 and compressive transformation rules 310 may be applied to only the extent necessary to reduce source text message 300 to a length that fits within specified length constraints.
A more detailed description of the contents of a message length reduction policy in accordance with a preferred embodiment of the present invention is presented in
The E-R (entity-relationship) approach to database modeling provides a semantics for the conceptual design of databases and data structures. With the E-R approach, database information is represented in terms of entities, attributes of entities, and relationships between entities, where the following definitions apply. The modeling semantics corresponding to each definition is illustrated in
Entity: An entity is a principal object about which information is collected. For example, in a database containing information about personnel of a company, an entity might be “Employee.” In E-R modeling, an entity is represented with a box. An entity may be termed weak or strong, relating its dependence on another entity. A strong entity exhibits no dependence on another entity, i.e. its existence does not require the existence of another Entity.
Attribute: An attribute is a label that gives a descriptive property to an entity (e.g., name, color, etc.). Two types of attributes exist. Key attributes distinguish among occurrences of an entity. For example, in the United States, a Social Security number is a key attribute that distinguishes between individuals. Descriptor attributes merely describe an entity occurrence (e.g., gender, weight). As shown in
Relationships: A relationship is a connectivity exhibited between entity occurrences. Relationships may be one to one, one to many, and many to many, and participation in a relationship by an entity may be optional or mandatory. For example, in the database containing information about personnel of a company, a relation “married to” among employee entity occurrences is one to one (if it is stated that an employee has at most one spouse). Further, participation in the relation is optional as there may exist unmarried employees. As a second example, if company policy dictates that every employee have exactly one manager, then the relationship “managed by” among employee entity occurrences is many to one (many employees may have the same manager), and mandatory (every employee must have a manager).
As shown in
A message length reduction profile may contain a personal dictionary of abbreviations to be applied to text messages. “Contains abbreviation” relation 606 relates a single instance of profile entity 600 to multiple instances of abbreviation entity 608 to form such a personal dictionary. Abbreviation entity 608 contains a pair of attributes. Text attribute 610, which is preferably a key attribute, represents a string of unabbreviated text to be represented by an abbreviation. Abbreviation text attribute 612 is a string containing an abbreviation that is intended to stand for the text contained in text attribute 610.
An instance of profile entity 600 may also have a number of associated compressive transformation rules, such as removing vowels or whitespace, that may be applied to a source text message. “Contains transformation rule” relation 614 maps a single instance of profile entity 600 to one or more instances of transformation rule entity 616. Each instance of transformation rule entity 616 has an associated “rule id” attribute 618 that may be used to uniquely identify a transformation rule represented by an instance of transformation rule entity 616. Having a unique identifier for each transformation rule allows rules to be selected by reference for inclusion into a message length reduction profile (i.e., rules may be included in a profile by referring to them simply by their identifiers). Transformation code attribute 620 represents a rule definition or program code for performing the compressive transformation represented by an instance of transformation rule entity 616. For instance, the pseudocode provided in
Additionally, as was stated earlier, a messaging device may store a number of message length reduction profiles associated with different recipient devices and/or users. “Associated with” relation 622 is a many-to-many (N-to-N) relation associating instances of profile entity 600 to devices or users, represented as instances of devices/users entity 624.
The overall operation of a messaging device abbreviating, compressing and transmitting a text message in accordance with a preferred embodiment of the present invention is depicted in flowchart form in
If the message is not an acceptable length (block 704:No), a determination is made as to whether an abbreviation from the personal dictionary of abbreviations associated with the message length reduction profile may be applied to the text message in its current form (block 706). If an abbreviation may be applied (block 706:Yes), the abbreviation is applied to the text message to shorten the message (block 708) and the process cycles to block 704.
If no abbreviation may be applied (block 706:No), a determination is made as to whether a compressive transformation rule from the message length reduction profile may be applied to the text message (block 710). If so (block 710:Yes), then the compressive transformation rule is applied to shorten the message (block 712) and the process cycles to block 704.
If no compressive transformation rule from the message length reduction profile can be applied (block 710:No) or if the text message has been determined to be at an acceptable length (block 704:Yes), the process continues to block 714. The relevant portions of the message length reduction profile are transmitted to the recipient messaging device (block 714). The “relevant portions” of the message length reduction profile may include those rules and abbreviations that were actually applied to the text message or may simply consist of some type of identifier to inform the recipient device of the message length reduction profile used to shorten the text message. Alternatively, the message length reduction profile may be transmitted in its entirety or in a compressed form (e.g., using conventional lossless compression techniques). In yet another alternative embodiment, block 714 may be omitted altogether, if it can be implicitly understood by the recipient messaging device which profile was used to shorten the text message. Finally, the shortened message is transmitted to the recipient messaging device (block 716).
Message length reduction profile information may be utilized in a number of ways by a recipient messaging device. For instance, when a message length reduction profile contains a personal dictionary of abbreviations, this personal dictionary may be used by the recipient device to replace the abbreviated forms of words and phrases with their full-length meanings through a reverse-lookup procedure. When the message length reduction profile associated with a text message indicates that one or more compressive transformation rules, such as eliminating vowels (or another subset of the character set or alphabet) or whitespace, have been applied to a text message, the effect of these rules may be reversed.
In accordance with a preferred embodiment of the present invention, a recipient device that receives a text message in which the vowels have been eliminated may make use of a data structure to map reduced character set words and phrases into full-length text.
Words/phrases entity 804 may have a number of attributes to aid in identifying the correct replacement word or phrase for a given reduced character set string. String attribute 805 contains the actual full-length text represented by words/phrases entity 804. A rank attribute 806 may include frequency information or other ranking information reflecting the probability that a given reduced character set string corresponds to a particular full-length word or phrase. Additional information attribute(s) 808 may contain contextual information or conditional probabilities to assist in the determination of which full-length word or phrase corresponds to a given reduced character set string in a text message.
If the end of the text message has not been reached (block 900:Yes), the next word (or phrase) in the text message is considered (some type of regular expression pattern matcher may be employed to find the next longest match for a word or phrase, thus allowing both words and phrases to be considered) (block 902). If the next word or phrase is a recognized abbreviation (block 904:Yes), then the abbreviation is simply replaced with its corresponding full-length text (block 905) and the process cycles to block 900 to consider subsequent words or phrases. If the word or phrase is not a recognized abbreviation (block 904:No), but is in reduced character set form (block 908:Yes), a lookup operation is performed to find possible words or phrases that the reduced character set string may represent (block 910). An appropriate choice of replacement word is then selected and applied to the text message (block 912). The process then (following block 912 or block 908:No) cycles to block 900 to iterate over subsequent words or phrases in the text message.
When the end of the text message has been reached (block 900:No), a determination is made as to whether the message has been accompanied by an error-detecting code, such as a cyclic redundancy check (CRC) calculated on the original full-length source text (block 913). Appending an error detection code to a shortened text message allows the accuracy of decompression to be checked. If no such error-detecting code accompanies the message (block 913:No), the process terminates. If an error-detecting code does accompany the message (block 913:Yes), then a determination is made as to whether the expanded text message is correct according to the error-detecting code (block 914). If so (block 914:Yes), then the process ends successfully. If not (block 914:No), then a determination is made as to whether all possible expansions have been exhausted (block 916). If not (block 916:No), the process cycles to step 900 to try another possible expansion. If so (block 916:Yes), however, the process terminates. Thus, if an error-detecting code is included with the text message, the correct expansion for the shortened text message can be found in a generate-and-test fashion.
One of ordinary skill in the art will also appreciate that a data structure such as that described in
In addition, other variations on the preferred embodiment are possible without departing from the scope and spirit of the present invention. For example, expanded text messages may be played back as audio speech using speech-synthesis technology. In addition, voice-recognition hardware or software may be employed to convert spoken word into a source text message for compression and abbreviation as needed, and subsequent transmission to a recipient device.
It is important to note that while the present invention has been described in the context of a fully functioning data processing system, those of ordinary skill in the art will appreciate that the processes of the present invention are capable of being distributed in the form of a non-transitory computer readable medium of instructions or other functional descriptive material and in a variety of other forms. Examples of non-transitory computer readable media include recordable-type media, such as a floppy disk, a hard disk drive, a RAM, CD-ROMs, DVD-ROMs. The non-transitory computer readable media may take the form of coded formats that are decoded for actual use in a particular data processing system. Functional descriptive material is information that imparts functionality to a machine. Functional descriptive material includes, but is not limited to, computer programs, instructions, rules, facts, definitions of computable functions, objects, and data structures.
The description of the present invention has been presented for purposes of illustration and description, and is not intended to be exhaustive or limited to the invention in the form disclosed. Many modifications and variations will be apparent to those of ordinary skill in the art. The embodiment was chosen and described in order to best explain the principles of the invention, the practical application, and to enable others of ordinary skill in the art to understand the invention for various embodiments with various modifications as are suited to the particular use contemplated.