AI Art Prints

AI Art Prints — independent reviews, comparisons, pricing and step-by-step guides on Aizhi.

  • Spectral shape analysis

    Spectral shape analysis

    Spectral shape analysis relies on the spectrum (eigenvalues and/or eigenfunctions) of the Laplace–Beltrami operator to compare and analyze geometric shapes. Since the spectrum of the Laplace–Beltrami operator is invariant under isometries, it is well suited for the analysis or retrieval of non-rigid shapes, i.e. bendable objects such as humans, animals, plants, etc. == Laplace == The Laplace–Beltrami operator is involved in many important differential equations, such as the heat equation and the wave equation. It can be defined on a Riemannian manifold as the divergence of the gradient of a real-valued function f: Δ f := div ⁡ grad ⁡ f . {\displaystyle \Delta f:=\operatorname {div} \operatorname {grad} f.} Its spectral components can be computed by solving the Helmholtz equation (or Laplacian eigenvalue problem): Δ φ i + λ i φ i = 0. {\displaystyle \Delta \varphi _{i}+\lambda _{i}\varphi _{i}=0.} The solutions are the eigenfunctions φ i {\displaystyle \varphi _{i}} (modes) and corresponding eigenvalues λ i {\displaystyle \lambda _{i}} , representing a diverging sequence of positive real numbers. The first eigenvalue is zero for closed domains or when using the Neumann boundary condition. For some shapes, the spectrum can be computed analytically (e.g. rectangle, flat torus, cylinder, disk or sphere). For the sphere, for example, the eigenfunctions are the spherical harmonics. The most important properties of the eigenvalues and eigenfunctions are that they are isometry invariants. In other words, if the shape is not stretched (e.g. a sheet of paper bent into the third dimension), the spectral values will not change. Bendable objects, like animals, plants and humans, can move into different body postures with only minimal stretching at the joints. The resulting shapes are called near-isometric and can be compared using spectral shape analysis. == Discretizations == Geometric shapes are often represented as 2D curved surfaces, 2D surface meshes (usually triangle meshes) or 3D solid objects (e.g. using voxels or tetrahedra meshes). The Helmholtz equation can be solved for all these cases. If a boundary exists, e.g. a square, or the volume of any 3D geometric shape, boundary conditions need to be specified. Several discretizations of the Laplace operator exist (see Discrete Laplace operator) for the different types of geometry representations. Many of these operators do not approximate well the underlying continuous operator. == Spectral shape descriptors == === ShapeDNA and its variants === The ShapeDNA is one of the first spectral shape descriptors. It is the normalized beginning sequence of the eigenvalues of the Laplace–Beltrami operator. Its main advantages are the simple representation (a vector of numbers) and comparison, scale invariance, and in spite of its simplicity a very good performance for shape retrieval of non-rigid shapes. Competitors of shapeDNA include singular values of Geodesic Distance Matrix (SD-GDM) and Reduced BiHarmonic Distance Matrix (R-BiHDM). However, the eigenvalues are global descriptors, therefore the shapeDNA and other global spectral descriptors cannot be used for local or partial shape analysis. === Global point signature (GPS) === The global point signature at a point x {\displaystyle x} is a vector of scaled eigenfunctions of the Laplace–Beltrami operator computed at x {\displaystyle x} (i.e. the spectral embedding of the shape). The GPS is a global feature in the sense that it cannot be used for partial shape matching. === Heat kernel signature (HKS) === The heat kernel signature makes use of the eigen-decomposition of the heat kernel: h t ( x , y ) = ∑ i = 0 ∞ exp ⁡ ( − λ i t ) φ i ( x ) φ i ( y ) . {\displaystyle h_{t}(x,y)=\sum _{i=0}^{\infty }\exp(-\lambda _{i}t)\varphi _{i}(x)\varphi _{i}(y).} For each point on the surface the diagonal of the heat kernel h t ( x , x ) {\displaystyle h_{t}(x,x)} is sampled at specific time values t j {\displaystyle t_{j}} and yields a local signature that can also be used for partial matching or symmetry detection. === Wave kernel signature (WKS) === The WKS follows a similar idea to the HKS, replacing the heat equation with the Schrödinger wave equation. === Improved wave kernel signature (IWKS) === The IWKS improves the WKS for non-rigid shape retrieval by introducing a new scaling function to the eigenvalues and aggregating a new curvature term. === Spectral graph wavelet signature (SGWS) === SGWS is a local descriptor that is not only isometric invariant, but also compact, easy to compute and combines the advantages of both band-pass and low-pass filters. An important facet of SGWS is the ability to combine the advantages of WKS and HKS into a single signature, while allowing a multiresolution representation of shapes. == Spectral Matching == The spectral decomposition of the graph Laplacian associated with complex shapes (see Discrete Laplace operator) provides eigenfunctions (modes) which are invariant to isometries. Each vertex on the shape could be uniquely represented with a combinations of the eigenmodal values at each point, sometimes called spectral coordinates: s ( x ) = ( φ 1 ( x ) , φ 2 ( x ) , … , φ N ( x ) ) for vertex x . {\displaystyle s(x)=(\varphi _{1}(x),\varphi _{2}(x),\ldots ,\varphi _{N}(x)){\text{ for vertex }}x.} Spectral matching consists of establishing the point correspondences by pairing vertices on different shapes that have the most similar spectral coordinates. Early work focused on sparse correspondences for stereoscopy. Computational efficiency now enables dense correspondences on full meshes, for instance between cortical surfaces. Spectral matching could also be used for complex non-rigid image registration, which is notably difficult when images have very large deformations. Such image registration methods based on spectral eigenmodal values indeed capture global shape characteristics, and contrast with conventional non-rigid image registration methods which are often based on local shape characteristics (e.g., image gradients).

    Read more →
  • Translation unit

    Translation unit

    In the field of translation, a translation unit is a segment of a text which the translator treats as a single cognitive unit for the purposes of establishing an equivalence. It may be a single word, a phrase, one or more sentences, or even a larger unit. When a translator segments a text into translation units, the larger these units are, the better chance there is of obtaining an idiomatic translation. This is true not only of human translation, but also where human translators use computer-assisted translation, such as translation memories, and when translations are performed by machine translation systems. == Perceptions on the concept of unit == Vinay and Darbelnet took to Saussure's original concepts of the linguistic sign when beginning to discuss the idea of a single word as a translation unit. According to Saussure, the sign is naturally arbitrary, so it can only derive meaning from contrast in other signs in that same system. However, Russian scholar Leonid Barkhudarov stated that, limiting it to poetry, for instance, a translation unit can take the form of a complete text. This seems to relate to his conception that a translation unit is the smallest unit in the source language with an equivalent in the target one, and when its parts are taken individually, they become untranslatable; these parts can be as small as phonemes or morphemes, or as large as entire texts. Susan Bassnett widened Barkhudarov's poetry perception to include prose, adding that in this type of translation text is the prime unit, including the idea that sentence-by-sentence translation could cause loss of important structural features. Swiss linguist Werner Koller connected Barkhudarov's idea of unit sizing to the difference between the two languages involved, by stating that the more different or unrelated these languages were, the larger the unit would be. One final perception on the idea of unit came from linguist Eugene Nida. To him, translation units have a tendency to be small groups of language building up into sentences, thus forming what he called meaningful mouthfuls of language. == Points of view towards translation units == === Process-oriented POV === According to this point of view, a translation unit is a stretch of text on which attention is focused to be represented as a whole in the target language. In this point of view we can consider the concept of the think-aloud protocol, supported by German linguist Wolfgang Lörscher: isolating units using self-reports by translating subjects. It also relates to how experienced the translator in question is: language learners take a word as a translation unit, whereas experienced translators isolate and translate units of meaning in the form of phrases, clauses or sentences. Since 1996 and 2005 keylogging and eyetracking technologies were introduced in Translation Process Research. These more advanced and non-invasive research methods made it possible to elaborate a finer-grained assessment of translation units as loops of (source or target text) reading and target text typing. Loops of translation units are thought to be the basic units by which translations are produced. Thus, Malmkjaer, for instance, defines process oriented translation units as a “stretch of the source text that the translator keeps in mind at any one time, in order to produce translation equivalents in the text he or she is creating” (p. 286). Records of keystrokes and eye movements allow to investigate these mental constructs through their physical (observable) behavioral traces in the translation process data. Empirical Translation Process Research has deployed numerous theories to explain and models the behavioral traces of these assumed mental units. === Product-oriented POV === Here, the target-text unit can be mapped into an equivalent source-text unit. A case study on this matter was reported by Gideon Toury, in which 27 English-Hebrew student-produced translations were mapped onto a source text. Those students that were less experienced had larger numbers of small units at word and morpheme level in their translations, while one student with translation experience had approximately half of those units, mostly at phrase or clause level.

    Read more →
  • Two-way finite automaton

    Two-way finite automaton

    In computer science, in particular in automata theory, a two-way finite automaton is a finite automaton that is allowed to re-read its input. == Two-way deterministic finite automaton == A two-way deterministic finite automaton (2DFA) is an abstract machine, a generalized version of the deterministic finite automaton (DFA) which can revisit characters already processed. As in a DFA, there are a finite number of states with transitions between them based on the current character, but each transition is also labelled with a value indicating whether the machine will move its position in the input to the left, right, or stay at the same position. Equivalently, 2DFAs can be seen as read-only Turing machines with no work tape, only a read-only input tape. 2DFAs were introduced in a seminal 1959 paper by Rabin and Scott, who proved them to have equivalent power to one-way DFAs. That is, any formal language which can be recognized by a 2DFA can be recognized by a DFA which only examines and consumes each character in order. Since DFAs are obviously a special case of 2DFAs, this implies that both kinds of machines recognize precisely the class of regular languages. However, the equivalent DFA for a 2DFA may require exponentially many states, making 2DFAs a much more practical representation for algorithms for some common problems. 2DFAs are also equivalent to read-only Turing machines that use only a constant amount of space on their work tape, since any constant amount of information can be incorporated into the finite control state via a product construction (a state for each combination of work tape state and control state). == Formal description == Formally, a two-way deterministic finite automaton can be described by the following 8-tuple: M = ( Q , Σ , L , R , δ , s , t , r ) {\displaystyle M=(Q,\Sigma ,L,R,\delta ,s,t,r)} where Q {\displaystyle Q} is the finite, non-empty set of states Σ {\displaystyle \Sigma } is the finite, non-empty set of input symbols L {\displaystyle L} is the left endmarker R {\displaystyle R} is the right endmarker δ : Q × ( Σ ∪ { L , R } ) → Q × { l e f t , r i g h t } {\displaystyle \delta :Q\times (\Sigma \cup \{L,R\})\rightarrow Q\times \{\mathrm {left,right} \}} s {\displaystyle s} is the start state t {\displaystyle t} is the end state r {\displaystyle r} is the reject state In addition, the following two conditions must also be satisfied: For all q ∈ Q {\displaystyle q\in Q} δ ( q , L ) = ( q ′ , r i g h t ) {\displaystyle \delta (q,L)=(q^{\prime },\mathrm {right} )} for some q ′ ∈ Q {\displaystyle q^{\prime }\in Q} δ ( q , R ) = ( q ′ , l e f t ) {\displaystyle \delta (q,R)=(q^{\prime },\mathrm {left} )} for some q ′ ∈ Q {\displaystyle q^{\prime }\in Q} It says that there must be some transition possible when the pointer reaches either end of the input word. For all symbols σ ∈ Σ ∪ { L } {\displaystyle \sigma \in \Sigma \cup \{L\}} δ ( t , σ ) = ( t , R ) {\displaystyle \delta (t,\sigma )=(t,R)} δ ( r , σ ) = ( r , R ) {\displaystyle \delta (r,\sigma )=(r,R)} δ ( t , R ) = ( t , L ) {\displaystyle \delta (t,R)=(t,L)} δ ( r , R ) = ( r , L ) {\displaystyle \delta (r,R)=(r,L)} It says that once the automaton reaches the accept or reject state, it stays in there forever and the pointer goes to the right most symbol and cycles there infinitely. == Two-way nondeterministic finite automaton == A two-way nondeterministic finite automaton (2NFA) may have multiple transitions defined in the same configuration. Its transition function is δ : Q × ( Σ ∪ { L , R } ) → 2 Q × { l e f t , r i g h t } {\displaystyle \delta :Q\times (\Sigma \cup \{L,R\})\rightarrow 2^{Q\times \{\mathrm {left,right} \}}} . Like a standard one-way NFA, a 2NFA accepts a string if at least one of the possible computations is accepting. Like the 2DFAs, the 2NFAs also accept only regular languages. == Two-way alternating finite automaton == A two-way alternating finite automaton (2AFA) is a two-way extension of an alternating finite automaton (AFA). Its state set is Q = Q ∃ ∪ Q ∀ {\displaystyle Q=Q_{\exists }\cup Q_{\forall }} where Q ∃ ∩ Q ∀ = ∅ {\displaystyle Q_{\exists }\cap Q_{\forall }=\emptyset } . States in Q ∃ {\displaystyle Q_{\exists }} and Q ∀ {\displaystyle Q_{\forall }} are called existential resp. universal. In an existential state a 2AFA nondeterministically chooses the next state like an NFA, and accepts if at least one of the resulting computations accepts. In a universal state 2AFA moves to all next states, and accepts if all the resulting computations accept. == State complexity tradeoffs == Two-way and one-way finite automata, deterministic and nondeterministic and alternating, accept the same class of regular languages. However, transforming an automaton of one type to an equivalent automaton of another type incurs a blow-up in the number of states. Christos Kapoutsis determined that transforming an n {\displaystyle n} -state 2DFA to an equivalent DFA requires n ( n n − ( n − 1 ) n ) {\displaystyle n(n^{n}-(n-1)^{n})} states in the worst case. If an n {\displaystyle n} -state 2DFA or a 2NFA is transformed to an NFA, the worst-case number of states required is ( 2 n n + 1 ) = O ( 4 n n ) {\displaystyle {\binom {2n}{n+1}}=O\left({\frac {4^{n}}{\sqrt {n}}}\right)} . Ladner, Lipton and Stockmeyer. proved that an n {\displaystyle n} -state 2AFA can be converted to a DFA with 2 n 2 n {\displaystyle 2^{n2^{n}}} states. The 2AFA to NFA conversion requires 2 Θ ( n log ⁡ n ) {\displaystyle 2^{\Theta (n\log n)}} states in the worst case, see Geffert and Okhotin. It is an open problem whether every 2NFA can be converted to a 2DFA with only a polynomial increase in the number of states. The problem was raised by Sakoda and Sipser, who compared it to the P vs. NP problem in the computational complexity theory. Berman and Lingas discovered a formal relation between this problem and the L vs. NL open problem, see Kapoutsis for a precise relation. == Sweeping automata == Sweeping automata are 2DFAs of a special kind that process the input string by making alternating left-to-right and right-to-left sweeps, turning only at the endmarkers. Sipser constructed a sequence of languages, each accepted by an n-state NFA, yet which is not accepted by any sweeping automata with fewer than 2 n {\displaystyle 2^{n}} states. == Two-way quantum finite automaton == The concept of 2DFAs was in 1997 generalized to quantum computing by John Watrous's "On the Power of 2-Way Quantum Finite State Automata", in which he demonstrates that these machines can recognize nonregular languages and so are more powerful than DFAs. == Two-way pushdown automaton == A pushdown automaton that is allowed to move either way on its input tape is called two-way pushdown automaton (2PDA); it has been studied by Hartmanis, Lewis, and Stearns (1965). Aho, Hopcroft, Ullman (1968) and Cook (1971) characterized the class of languages recognizable by deterministic (2DPDA) and non-deterministic (2NPDA) two-way pushdown automata; Gray, Harrison, and Ibarra (1967) investigated the closure properties of these languages.

    Read more →
  • Top 10 AI Chatbots Compared (2026)

    Top 10 AI Chatbots Compared (2026)

    Shopping for the best AI chatbot? An AI chatbot is software that uses machine learning to help you get more done — it keeps getting smarter as the underlying models improve. Pricing, accuracy, and the size of the model behind the tool are the three factors that most affect daily usefulness. Whether you are a beginner or a pro, the right AI chatbot slots into your workflow and pays for itself fast. Below we compare features, pricing, and real output so you can choose with confidence.

    Read more →
  • Switch (app)

    Switch (app)

    Switch was a mobile-only job-matching app that connected candidates directly to hiring managers. Candidates could upload their resumes and connect their social and professional media profiles, but remain anonymous while searching. Users received a daily set of job recommendations that fit their backgrounds and salary criteria, and swipe right to apply. Employers post many jobs on Switch directly, which eliminates the need for third-party job boards and recruiters, and connects job seekers to hiring managers. Switch reveals a candidate’s identity to one employer at a time, only after the candidate matches with that employer. When candidates and employers match, they can chat within the app. Switch is available for iOS, with an Android version in development. == History == === Founding === Yarden Tadmor founded Switch in New York City in January 2014. For the first 10 months, Tadmor funded the company himself. By December 2014, Switch had raised $1.4 million in funding from venture capitals firms Metamorphic Ventures, SG VC, BAM and Rhodium. Tadmor's inspiration for Switch came after being frustrated by his experience both as a job seeker, and also as a supervisor hiring at numerous technology startup companies. Tadmor has said of Switch, “We operate on the five-second resume principle, which is usually the amount of time a recruiter spends on a resume. They scan through the typical data points and move on.” Switch was designed for passive job seekers to browse openings discreetly and connect quickly. Originally, Switch served only the New York metro area technology sector while in early beta, but Tadmor always intended to expand into national coverage. Soon, the company started including all major metropolitan markets across the U.S. In May 2015, Switch announced it would start sourcing tech and media jobs from all the job boards available online. Later in 2015, Switch began to post jobs in smaller urban areas. The company also expanded industries and jobs to include restaurant staff, retail sales, healthcare, nursing and education. Tadmor subsequently founded Livekick, a one-on-one private fitness and yoga instruction company, based in New York. == Operation == In May 2015, Switch reported generating over 400,000 job applications. The company said that nine of the 50 largest websites in the U.S. were using the service. It had grown its customer base to thousands of companies in a few months from launch including Microsoft, Amazon, Facebook, IBM, Yahoo!, eBay, DropBox, SoundCloud, and Wikipedia. John Cline, software development manager at eBay, told ABC’s Good Morning America that Switch is now his “main way of finding new prospective employees.” Switch uses a double opt-in technique, meaning job seekers and employers must both say yes before moving forward. They also use swiping technology and intelligent matching algorithms to connect job seekers and employers. The user experience is different for each group, but the major attraction for both sides is the speed at which they can be connected. === Features === Swipe is a major aspect of the Switch user experience. Job seekers swipe to apply to jobs, or left to pass on positions. Employers respond and swipe right to reciprocate interest, or left to eliminate the candidate. Direct connection between job seekers and employers allows hiring managers and job seekers to start an immediate conversation. Hiring managers can message with job seekers within the app, and both parties can quickly vet one another and decide whether to move forward. Easy profile creation from social media and in-app profile editing helps job seekers focus on finding a job. === Users === Job Seekers can either load their profile manually or pull in professional credentials from social media. They can post validated photos on their Facebook account. Switch’s matching algorithm analyzes the job seeker’s location, experience, and skills to bring them jobs they may be interested in. Job seekers swipe to apply and, if the employer shows interest too, only then does Switch’s system reveal the job seeker’s identity to the corporate recruiter or hiring manager. The job seeker and hiring manager can then chat through the app. Employers behave similarly to job seekers. Hiring managers or corporate recruiters sign up online, add open positions, then view Switch-recommended candidates or wait for job seekers to swipe right. Employers can select relevant job seekers by swiping right on their profiles, then chat directly in the app. === Subscriptions === The app is currently free for users and employers. == Company overview == === Financials === Switch closed out its seed round in May 2015 with $2 million in seed round funding. Investors include Marker VC, Metamorphic, Rhodium, 500 Startups, BAM, SG VC and Marcel Legrand. In a July 2015 interview with Tadmor, he claimed that Switch had raised $2.4 million to date. == Reception == Thanks to its swipe technology and double opt-in make-up, the media often refers to Switch as the Tinder for jobs. Switch has received features in lists and app reviews as an effective tool to improve your digital job search, particularly on the mobile platform. “It’s minimal effort to connect with relevant matches,” said Good Morning America workplace contributor Tory Johnson. “Which is what everybody wants to find.”

    Read more →
  • Probabilistic context-free grammar

    Probabilistic context-free grammar

    In theoretical linguistics and computational linguistics, probabilistic context free grammars (PCFGs) extend context-free grammars, similar to how hidden Markov models extend regular grammars. Each production is assigned a probability. The probability of a derivation (parse) is the product of the probabilities of the productions used in that derivation. These probabilities can be viewed as parameters of the model, and for large problems it is convenient to learn these parameters via machine learning. A probabilistic grammar's validity is constrained by context of its training dataset. PCFGs originated from grammar theory, and have application in areas as diverse as natural language processing to the study the structure of RNA molecules and design of programming languages. Designing efficient PCFGs has to weigh factors of scalability and generality. Issues such as grammar ambiguity must be resolved. The grammar design affects results accuracy. Grammar parsing algorithms have various time and memory requirements. == Definitions == Derivation: The process of recursive generation of strings from a grammar. Parsing: Finding a valid derivation using an automaton. Parse Tree: The alignment of the grammar to a sequence. An example of a parser for PCFG grammars is the pushdown automaton. The algorithm parses grammar nonterminals from left to right in a stack-like manner. This brute-force approach is not very efficient. In RNA secondary structure prediction variants of the Cocke–Younger–Kasami (CYK) algorithm provide more efficient alternatives to grammar parsing than pushdown automata. Another example of a PCFG parser is the Stanford Statistical Parser which has been trained using Treebank. == Formal definition == Similar to a CFG, a probabilistic context-free grammar G can be defined by a quintuple: G = ( M , T , R , S , P ) {\displaystyle G=(M,T,R,S,P)} where M is the set of non-terminal symbols T is the set of terminal symbols R is the set of production rules S is the start symbol P is the set of probabilities on production rules == Relation with hidden Markov models == PCFGs models extend context-free grammars the same way as hidden Markov models extend regular grammars. The Inside-Outside algorithm is an analogue of the Forward-Backward algorithm. It computes the total probability of all derivations that are consistent with a given sequence, based on some PCFG. This is equivalent to the probability of the PCFG generating the sequence, and is intuitively a measure of how consistent the sequence is with the given grammar. The Inside-Outside algorithm is used in model parametrization to estimate prior frequencies observed from training sequences in the case of RNAs. Dynamic programming variants of the CYK algorithm find the Viterbi parse of a RNA sequence for a PCFG model. This parse is the most likely derivation of the sequence by the given PCFG. == Grammar construction == Context-free grammars are represented as a set of rules inspired from attempts to model natural languages. The rules are absolute and have a typical syntax representation known as Backus–Naur form. The production rules consist of terminal { a , b } {\displaystyle \left\{a,b\right\}} and non-terminal S symbols and a blank ϵ {\displaystyle \epsilon } may also be used as an end point. In the production rules of CFG and PCFG the left side has only one nonterminal whereas the right side can be any string of terminal or nonterminals. In PCFG nulls are excluded. An example of a grammar: S → a S , S → b S , S → ϵ {\displaystyle S\to aS,S\to bS,S\to \epsilon } This grammar can be shortened using the '|' ('or') character into: S → a S | b S | ϵ {\displaystyle S\to aS|bS|\epsilon } Terminals in a grammar are words and through the grammar rules a non-terminal symbol is transformed into a string of either terminals and/or non-terminals. The above grammar is read as "beginning from a non-terminal S the emission can generate either a or b or ϵ {\displaystyle \epsilon } ". Its derivation is: S ⇒ a S ⇒ a b S ⇒ a b b S ⇒ a b b {\displaystyle S\Rightarrow aS\Rightarrow abS\Rightarrow abbS\Rightarrow abb} Ambiguous grammar may result in ambiguous parsing if applied on homographs since the same word sequence can have more than one interpretation. Pun sentences such as the newspaper headline "Iraqi Head Seeks Arms" are an example of ambiguous parses. One strategy of dealing with ambiguous parses (originating with grammarians as early as Pāṇini) is to add yet more rules, or prioritize them so that one rule takes precedence over others. This, however, has the drawback of proliferating the rules, often to the point where they become difficult to manage. Another difficulty is overgeneration, where unlicensed structures are also generated. Probabilistic grammars circumvent these problems by ranking various productions on frequency weights, resulting in a "most likely" (winner-take-all) interpretation. As usage patterns are altered in diachronic shifts, these probabilistic rules can be re-learned, thus updating the grammar. Assigning probability to production rules makes a PCFG. These probabilities are informed by observing distributions on a training set of similar composition to the language to be modeled. On most samples of broad language, probabilistic grammars where probabilities are estimated from data typically outperform hand-crafted grammars. CFGs when contrasted with PCFGs are not applicable to RNA structure prediction because while they incorporate sequence-structure relationship they lack the scoring metrics that reveal a sequence structural potential == Weighted context-free grammar == A weighted context-free grammar (WCFG) is a more general category of context-free grammar, where each production has a numeric weight associated with it. The weight of a specific parse tree in a WCFG is the product (or sum ) of all rule weights in the tree. Each rule weight is included as often as the rule is used in the tree. A special case of WCFGs are PCFGs, where the weights are (logarithms of ) probabilities. An extended version of the CYK algorithm can be used to find the "lightest" (least-weight) derivation of a string given some WCFG. When the tree weight is the product of the rule weights, WCFGs and PCFGs can express the same set of probability distributions. == Applications == === RNA structure prediction === Since the 1990s, PCFG has been applied to model RNA structures. Energy minimization and PCFG provide ways of predicting RNA secondary structure with comparable performance. However structure prediction by PCFGs is scored probabilistically rather than by minimum free energy calculation. PCFG model parameters are directly derived from frequencies of different features observed in databases of RNA structures rather than by experimental determination as is the case with energy minimization methods. The types of various structure that can be modeled by a PCFG include long range interactions, pairwise structure and other nested structures. However, pseudoknots can not be modeled. PCFGs extend CFG by assigning probabilities to each production rule. A maximum probability parse tree from the grammar implies a maximum probability structure. Since RNAs preserve their structures over their primary sequence, RNA structure prediction can be guided by combining evolutionary information from comparative sequence analysis with biophysical knowledge about a structure plausibility based on such probabilities. Also search results for structural homologs using PCFG rules are scored according to PCFG derivations probabilities. Therefore, building grammar to model the behavior of base-pairs and single-stranded regions starts with exploring features of structural multiple sequence alignment of related RNAs. S → a S a | b S b | a a | b b {\displaystyle S\to aSa|bSb|aa|bb} The above grammar generates a string in an outside-in fashion, that is the basepair on the furthest extremes of the terminal is derived first. So a string such as a a b a a b a a {\displaystyle aabaabaa} is derived by first generating the distal a's on both sides before moving inwards: S ⇒ a S a ⇒ a a S a a ⇒ a a b S b a a ⇒ a a b a a b a a {\displaystyle S\Rightarrow aSa\Rightarrow aaSaa\Rightarrow aabSbaa\Rightarrow aabaabaa} A PCFG model extendibility allows constraining structure prediction by incorporating expectations about different features of an RNA . Such expectation may reflect for example the propensity for assuming a certain structure by an RNA. However incorporation of too much information may increase PCFG space and memory complexity and it is desirable that a PCFG-based model be as simple as possible. Every possible string x a grammar generates is assigned a probability weight P ( x | θ ) {\displaystyle P(x|\theta )} given the PCFG model θ {\displaystyle \theta } . It follows that the sum of all probabilities to all possible grammar productions is ∑ x P ( x | θ ) = 1 {\displaystyle \sum _{\text{x}}P(x|\theta )=1} . The scores

    Read more →
  • Machine translation in China

    Machine translation in China

    Machine translation in China is the history of machine translation systems developed in China. China became the fourth country that began machine translation (MT) research following USA, UK, and the Soviet Union. In 1957, the Language Institute of Chinese Academy of Sciences took the initiative in Russian-Chinese MT research program and set up an MT research group. From then on the research activities were directed and applied for academic purposes in Universities. The turning point of MT systems launching initiatives in market began from 1990s. MT systems went into blossom into the market. Among these systems, there were commercialized MT systems. To be more specific, Transtar was the first commercialized MT system and has been constantly upgraded. What's more, IMC/EC MT system which was developed by Computer Institute of Chinese Academy of Sciences has further made great advancement. Meanwhile, the practical MT system MT-IT-EC specific to communication domain was also striking to notice, for it has greatly improved the efficiency and productivity in the issue of publications. Government funding is a critical component and support in the development of market-oriented machine translation in China. It is evident to see that since Chinese opened up to the outside world and joined the WTO, the vigorous import and export trade generate opportunities for machine translation to transfer technical terms of products into the readable target information. Facing the increasing demand of sophisticated state-of -the -art translation technology, the academic area including research institute and universities are even launching bachelors’ and master's programs regarding machine translation. Thus, strong evidence illustrates the promising field of machine translation in the future market of China.

    Read more →
  • Best AI Background Removers in 2026

    Best AI Background Removers in 2026

    Comparing the best AI background remover? An AI background remover is software that uses machine learning to help you get more done — it lowers the barrier so anyone can produce professional output. Privacy matters too: check whether your data trains the model and whether a no-log or enterprise tier is available. Whether you are a beginner or a pro, the right AI background remover slots into your workflow and pays for itself fast. We tested the leading options and ranked them by quality, value, and ease of use.

    Read more →
  • Douglas Parkhill

    Douglas Parkhill

    Douglas F. Parkhill is a Canadian technologist and former research minister, best known for his pioneering work on what is now called cloud computing, and his work on Canada's Telidon videotex project. He started working at the Canadian ministry of Communications (now part of the Department of Trade and Industry) in 1969, having previously worked at the Mitre Corporation. He was responsible for many activities in communications satellites, computer communications, command and control systems and telecommunications. He was winner of the Treasury Board of Canada Secretariat's Outstanding Achievement award in 1982, the Conestoga shield for services to government and industry in computer communications research and development, the Touche Ross award for Telidon development. He was an author of several publications including the 1966 book, The Challenge of the Computer Utility. In the book, Parkhill thoroughly explored many of the modern-day characteristics of cloud computing (elastic provisioning through a utility service) as well as the comparison to the electricity industry and the use of public, private, government and community forms. The book won the McKinsey Foundation award for distinguished contributions to management literature. He worked with Dave Godfrey, the Canadian writer and novelist on a later book Gutenberg two about the social and political meaning of computer technology. He was in charge of research at the Federal Department of Communications at the time when the department was funding development of the Telidon videotext system, was heavily involved in promoting the system, and had overall control of the program. In a radio broadcast in 1980, he outlined some of the potential of the system, from financial information, to theatre reservations, with the ability to pay and print out tickets from the system. He later documented the history of the Telidon project, and the history of videotext in general. == Publications == The Challenge of the Computer Utility, Addison-Wesley, 1966, ISBN 0-201-05720-4 edited with Dave Godfrey, Gutenberg Two: The New Electronics and Social Change, Press Porcepic, 1979, ISBN 0-88878-191-1 The Beginning of a Beginning. Ottawa; Department of Communications, 1987. A history of the Telidon project.

    Read more →
  • MedSLT

    MedSLT

    MedSLT is a medium-ranged open source spoken language translator developed by the University of Geneva. It is funded by the Swiss National Science Foundation. The system has been designed for the medical domain. It currently covers the doctor-patient diagnosis dialogues for the domains of headache, chest and abdominal pain in English, French, Japanese, Spanish, Catalan and Arabic. The vocabulary used ranges from 350 to 1000 words depending on the domain and language pair. == Motivation for creating MedSLT == With more than 6000 languages worldwide, language barriers become an increasing problem for healthcare. The lack of medical interpreters can lead to disastrous consequences. These range from prolonged hospital stays to wrong diagnosis and medication. A study found that only about half of the 23 million people with limited proficiency in English in the United States had been provided with a medical interpreter. Millions of refugees and immigrants worldwide face similar problems, although not always as severe. The gap between need and availability of language services might be closed with speech translation systems. == Challenges == The biggest challenge is and was to develop an ideal system, though it is not possible to do so at this moment. This system would fit the needs of doctors and the patients alike, and would provide accurate and flexible translation. A realisation of an ideal translation tool is impossible without the use of unrestricted language and a large vocabulary. Medical professionals demand high reliability from translation. This favours rule-based architectures over data-driven. The latter are more suitable for inexperienced users. Rule-based architectures achieve higher accuracy especially if used by experts. Though it is highly desirable to build a bidirectional system supporting a two-way dialogue, which concentrates on patient-centered communication, the patients will have difficult access to the system. Most patients have no experience with such systems. Less reliable results for translation from the patient-to-doctor direction are the outcome. To overcome this the system needs to provide either easy access or an integrated help tool to guide the users through the process. Although controlled rule-based systems achieve good results, they are brittle. To receive good translations the user needs to be familiar with the system and has to know what is covered by the grammar. Covering different sub-domains (headache, chest and abdominal pain) and language pairs presents additional problems. A shared structure and grammar for all subdomains and language pairs minimises development and maintenance costs. The integration of new doctor and patient languages is also a key challenge. Adding new languages should be quick and rather simple, because he system has to be used in many countries to cover multiple language pairs. Direct translation from source to target language proves to be rather difficult. Using interlingua for unidirectional translation instead of a bidirectional approach helps to simplify the translation process. On top of this, the system has to run on different platforms, because mobility is a key issue for many attending physicians. A portable version addresses these issues, but has to deal with the heavy load of the translation process. == The MedSLT system == The system's speech recognition is based on the Nuance 8.5 platform that supports grammar-based language models. All grammars used for recognition, analysis and generation are compiled from a small set of unification grammars. These core grammars are created by the open-source Regulus Grammar Compiler and are automatically specialised using corpus-driven methods. The specialisation considers both the task (recognition, analysis and generation) and the sub-domain (headache, chest and abdominal pain). The specialisation uses the explanation-based learning algorithm to create a treebank from the training corpus. These examples are divided into sets of subtrees by using domain- and grammar-specific rules (also known as "operationality criteria" in machine translation). The subtree rules are combined into a single rule, creating a specialised unification grammar. The grammar is compiled to an executable form, for analysis and generation by a parser or generator, and for recognition of a CFG grammar. A CFG grammar is required for the Nuance engine. Compilation by Nuance-specific criteria turns the grammar into speech recognition packages. The final step uses the training corpus again for statistical tuning of the language model. MedSLT translation processes are based on a rule-based interlingua. The interlingua is treated as an actual language (it is a very simple version of English) and is specified by a Regulus grammar. This grammar does not take account of complex surface syntax phenomena of real languages like movement or agreement. A set of rules is the base for translating the source language semantic representation to interlingua. Another set of rules covers the translation from interlingua to the target language. The semantic representations are converted to surface words using a target language grammar. Defining semantics for a specific domain enables the developers to specify interlingua with a small, tightly constraint semantic grammar. The translations based on interlingua match direct translations almost perfectly, because the development shifts to a decoupled monolingual architecture. A set of combined interlingua corpora, with one corpus per sub-domain, is the core of this architecture. All source language development corpora are translated to interlingua. These are sorted and grouped together with the corresponding source language examples. The interlingua forms are then translated into each target language, and the results are attached together. This organisation improves the translation process. There is no duplicated effort for multilingual regression testing, because each parsing and generation step is performed once. This allows more frequent testing. The representation language used for all forms is Almost Flat Functional semantics. AFF is derived from the Spoken Language Translator, the precursor of MEdSLT. SLT uses Quasi Logical Form, a logical based representation language. QLF is an expressive yet very complex language, causing high development and maintenance costs. A minimal solution was planned for the medical translator. Early versions of the system utilised a language using simple feature-value lists. These lists were supplemented with an optional level of nesting to represent subordinate clauses (i.e. embedded clauses). Determiners were not included, because they are hard to translate and it is difficult to reliably distinguish and recognise them. This way, translation rules became a lot simpler, because only a list of feature-value pairs had to be mapped to another list of pairs. The language turned out to be underconstrained. Adding natural sortal constraints to the grammar solved this problem, but also returned the language to a more expressive formalism. The newly created AFF combines elements of QLF and the feature-value list semantics. This version of flat semantics is enhanced with additional functional markings. This together with a relatively small vocabulary solved the ambiguity problem of the original flat representation language without creating overly complex rules. In addition, the syntactic structures are treated carefully by a compromise of linguistic and engineering traditions. The grammars are in fact retrieved from linguistically motivated resource, using corpus-based methods. They are driven by small sets of examples. This results in simpler and flatter domain-specific grammars. The semantics are less sophisticated and represent a minimal approach in the engineering tradition. Each lexical item contributes a set of feature-value pairs. This leads to simple-to-write translation rules. There are only lists of features-value pairs to map to other feature-value pairs. However, as a result the machine translation channel model becomes underspecified and is weakened, whereas the target language model is strengthened. An intelligent help module is integrated into the system to support users in utilising the full coverage of the grammars. This tool provides the user with examples as close as possible to the users original utterance. The output is based on a library. Each sub-domain and language pair has its own library. The contents are extracted from the combined interlingua corpora. The help module scans the corpus for the tagged source language form mapped with the corresponding target language form. Additionally a second statistical recogniser is used as backup. The results are used to select similar examples from the library. According to the generation preferences, one of the derived strings is picked and the target language string is realised as spoken language. Some statistical corpus based meth

    Read more →
  • Is an AI Essay Writer Worth It in 2026?

    Is an AI Essay Writer Worth It in 2026?

    Comparing the best AI essay writer? An AI essay writer is software that uses machine learning to help you get more done — it lowers the barrier so anyone can produce professional output. Privacy matters too: check whether your data trains the model and whether a no-log or enterprise tier is available. Whether you are a beginner or a pro, the right AI essay writer slots into your workflow and pays for itself fast. Below we compare features, pricing, and real output so you can choose with confidence.

    Read more →
  • Foma (software)

    Foma (software)

    Foma is a free and open source finite-state toolkit created and maintained by Mans Hulden. It includes a compiler, programming language, and C library for constructing finite-state automata and transducers (FST's) for various uses, most typically Natural Language Processing uses such as morphological analysis. Foma can replace the proprietary Xerox Finite State Toolkit for compiling and running FST's written in the lexc and xfst formalisms. The speed is comparable with the Xerox tools for most lexicons, although Foma can be 3 or 4 times slower for very large lexicons (e.g. >100,000 words). Foma is also one of the possible backends of the free and open source Helsinki Finite State Toolkit (where other backends provide support for further formalisms). There are several FOSS morphologies written in lexc/xfst compatible with foma, e.g. for the Sámi, Cornish, Faroese, Finnish, Komi, Mari, Udmurt, Buriat, Greenlandic language and Iñupiaq languages.

    Read more →
  • Colour banding

    Colour banding

    Colour banding is a subtle form of posterisation in digital images, caused by the colour of each pixel being rounded to the nearest of the digital colour levels. While posterisation is often done for artistic effect, colour banding is an undesired artefact. In 24-bit colour modes, 8 bits per channel is usually considered sufficient to render images in Rec. 709 or sRGB. However the eye can see the difference between the colour levels, especially when there is a sharp border between two large areas of adjacent colour levels. This will happen with gradual gradients (like sunsets, dawns or clear blue skies), and also when blurring an image a large amount. Colour banding is more noticeable with fewer bits per pixel (BPP) at 16–256 colours (4–8 BPP), where there are fewer shades with a larger difference between them. The appearance of colour banding is exaggerated by the Mach bands effect. Possible solutions include the introduction of dithering and increasing the number of bits per colour channel. Because the banding comes from limitations in the presentation of the image, blurring the image does not fix this unless the image BPP is higher than the original.

    Read more →
  • Babak Hodjat

    Babak Hodjat

    Babak Hodjat (Persian: بابک حجت; born November 1, 1967) is a British computer scientist, entrepreneur, and writer. He was the co-founder and CEO of Sentient Technologies and now holds the position of Chief Technology Officer AI at Cognizant. He is a specialist in the field of artificial intelligence and machine learning. In 1998 Hodjat co-founded Dejima Inc and served as CEO and CTO, his patented work on artificial intelligence led to the technology used by Apple for their digital assistant Siri. == Biography == === Early life === Babak Hodjat was born on November 1, 1967, in Wimbledon. His father was a retired university professor in entomology who worked at the British Museum. As a child, he did not like insects and would wander off to the nearby science museum, where he would spend long hours in front of a computer they had on display. He attended middle school in the United States. He studied at the Sharif University of Technology from 1986 to 1995, and received his Master of Science degree in software engineering. In 1994, together with another computer department student Hormoz Shahrzad presented their research titled Introducing a dynamic problem solving scheme based on a learning algorithm in artificial life environments at the first IEEE Conference on Computational Intelligence held at Orlando. Hodjat received a PhD in machine intelligence from Kyushu University in 2003 During his time there, he published several works on adaptive agent oriented software architecture and natural language user interfaces. === Career in science and business === Hodjat moved to Silicon Valley, California in 1998 and founded Dejima Inc. (named after the historic Japanese Dejima artificial island). The firm was based on a patented adaptive agent-oriented software engineering platform developed by Hodjat, Christopher Savoie and Makoto Amamiya. Hodjat served as the CTO and as the CEO for 9 months from October 2000. By 2000 the company had offices in San Jose, London and Tokyo. In 2002, the company developed a voice control Natural Interaction Platform (NPI) in collaboration with the Stanford University's research group Archimedes Project. During these years Hodjat continued his research on agent oriented software architecture and natural language user interfaces. In July 2003, Dejima got funding from SRI International within the Cognitive Assistant that Learns and Organizes (CALO) project of DARPA and worked on a Perceptive Assistant that Learns (PAL) initiative. Hodjat was the primary inventor of the firm's agent-oriented technology applied to intelligent interfaces for mobile and enterprise computing – a technology that eventually led to Siri. In April 2004, Dejima was acquired by Sybase iAnywhere. Hodjat served as senior director of engineering at Sybase iAnywhere from 2004 to 2008, where he developed AvantGo Platform, mBusiness Anywhere, and Answers Anywhere. In 2006, he co-founded MobileVerbs Inc., a mobile marketing service company, which was acquired by iLoop Mobile in February 2010. In 2007, he teamed with Antoine Blondeau (former CEO of Dejima) and Adam Cheyer (Dejima's vice president and Chief Architect of the CALO project) to establish Genetic Finance Holding Ltd. (where he began as CTO). In 2014 the firm became Sentient Technologies. Hodjat was joined by his long-time research fellow Hormoz Shahrzad who became principal scientist, while Hodjat held the position of chief scientist. In the following years Hodjat has worked on developing massively distributed computing technology and improving machine-learning technique known as evolutionary algorithms. One area that gained special attention from the press was applying Sentient Technologies algorithms to a stock market trading through specially created Sentient Investment Management hedge fund. Following the management change within Sentient Technologies, Hodjat became the company's CEO in February 2017. He continues his business and educational projects (he was on the jury of IBM Watson AI XPRIZE and the Merit Awards committee for the ISAL Award). == Writing == Hodjat is the author of multiple books such as The Konar and the Apple: Fun, Beauty, and Dread--From Ahwaz to California and the science fiction novel "The Narrator" (January 2022; ISBN 978-1-7354860-1-7)(March 2023; ISBN 978-1-7354860-0-0). == Selected publications == Hodjat, B.; Shahrzad, H. (1994). "Introducing a dynamic problem solving scheme based on a learning algorithm in artificial life environments". IEEE International Joint Conference on neural networks (IJCNN-94). Vol. 4. IEEE International Joint Conference on neural networks. pp. 2333–2338. doi:10.1109/ICNN.1994.374583. ISBN 978-0-7803-1901-1. S2CID 60497133. Hodjat, B.; Savoie, C.J.; Amamiya, M. (2006) [1998]. "An adaptive agent oriented software architecture". PRICAI'98: Topics in Artificial Intelligence. Springer. pp. 33–46. arXiv:cs/9812014. doi:10.1007/BFb0095256. ISBN 978-3-540-49461-4. S2CID 5317786. Hodjat, B.; Amamiya, M. (2000-05-25). "Applying the Adaptive Agent Oriented Software Architecture to the Parsing of Context Sensitive Grammars". IEICE Transactions on Information and Systems. E83-D (5): 1142–1152. ISSN 0916-8532. Retrieved 2017-12-14. Hodjat, Babak; Hodjat, Siamak; Treadgold, Nick; Jonsson, Ing-Marie (2006). "CRUSE: a context reactive natural language mobile interface". Proceedings of the 2nd annual international workshop on Wireless internet. WICON. doi:10.1145/1234161.1234181. ISBN 978-1-59593-510-6. S2CID 2388254. O'Reilly, Una-May; Wagy, Mark; Hodjat, Babak (2013). "Chapter 6: EC-Star: A Massive-Scale, Hub and Spoke, Distributed Genetic Programming System". In Riolo, R.; Vladislavleva, E.; Ritchie, M.; Moore, J.H. (eds.). Genetic Programming Theory and Practice X. Springer-Verlag New York. pp. 73–85. doi:10.1007/978-1-4614-6846-2. ISBN 978-1-4614-6845-5. S2CID 39650969. Retrieved 2017-12-14. Hodjat, Babak; Hemberg, Erik; Shahrzad, Hormoz; O'Reilly, Una-May (2014). "Chapter 4: Maintenance of a Long Running Distributed Genetic Programming System for Solving Problems Requiring Big Data". In Riolo, Rick; Moore, Jason H.; Kotanchek, Mark (eds.). Genetic Programming Theory and Practice XI. Springer-Verlag New York. pp. 65–83. doi:10.1007/978-1-4939-0375-7. ISBN 978-1-4939-0374-0. S2CID 28843739. Retrieved 2017-12-14. Shahrzad, Hormoz; Hodjat, Babak; Miikkulainen, Risto (2016). "Estimating the Advantage of Age-Layering in Evolutionary Algorithms". Proceedings of the Genetic and Evolutionary Computation Conference 2016. Genetic and Evolutionary Computation Conference. pp. 693–699. doi:10.1145/2908812.2908911. ISBN 978-1-4503-4206-3. S2CID 215516530. == Patents == Babak Hodjat holds 21 patents in the fields of agent-oriented programming, natural language decision engines, distributed evolutionary algorithms for asset management and trading and data mining.

    Read more →
  • Trie

    Trie

    In computer science, a trie (, ), also known as a digital tree or prefix tree, is a specialized search tree data structure used to store and retrieve strings from a dictionary or set. Unlike a binary search tree, nodes in a trie do not store their associated key. Instead, each node's position within the trie determines its associated key, with the connections between nodes defined by individual characters rather than the entire key. Tries are particularly effective for tasks such as autocomplete, spell checking, and IP routing, offering advantages over hash tables due to their prefix-based organization and lack of hash collisions. Every child node shares a common prefix with its parent node, and the root node represents the empty string. While basic trie implementations can be memory-intensive, various optimization techniques such as compression and bitwise representations have been developed to improve their efficiency. A notable optimization is the radix tree, which provides more efficient prefix-based storage. While tries store character strings, they can be adapted to work with any ordered sequence of elements, such as permutations of digits or shapes. A notable variant is the bitwise trie, which uses individual bits from fixed-length binary data (such as integers or memory addresses) as keys. == History, etymology, and pronunciation == The idea of a trie for representing a set of strings was first abstractly described by Axel Thue in 1912. Tries were first described in a computer context by René de la Briandais in 1959. The idea was independently described in 1960 by Edward Fredkin, who coined the term trie, pronouncing it (as "tree"), after the middle syllable of retrieval. However, other authors pronounce it (as "try"), in an attempt to distinguish it verbally from "tree". == Overview == Tries are a form of string-indexed look-up data structure, which is used to store a dictionary list of words that can be searched on in a manner that allows for efficient generation of completion lists. A prefix trie is an ordered tree data structure used in the representation of a set of strings over a finite alphabet set, which allows efficient storage of words with common prefixes. Tries can be efficacious on string-searching algorithms such as predictive text, approximate string matching, and spell checking in comparison to binary search trees. A trie can be seen as a tree-shaped deterministic finite automaton. == Operations == Tries support various operations: insertion, deletion, and lookup of a string key. Tries are composed of nodes that contain links, which either point to other suffix child nodes or null. As for every tree, each node except the root is pointed to by only one other node, called its parent. Each node contains as many links as the number of characters in the applicable alphabet (although tries tend to have a substantial number of null links). In some cases, the alphabet used is simply that of the character encoding—resulting in, for example, a size of 128 in the case of ASCII. The null links within the children of a node emphasize the following characteristics: Characters and string keys are implicitly stored in the trie, and include a character sentinel value indicating string termination. Each node contains one possible link to a prefix of strong keys of the set. A basic structure type of nodes in the trie is as follows: Node {\displaystyle {\text{Node}}} may contain an optional Value {\displaystyle {\text{Value}}} , which is associated with the key that corresponds to the node. === Searching === Searching for a value in a trie is guided by the characters in the search string key, as each node in the trie contains a corresponding link to each possible character in the given string. Thus, following the string within the trie yields the associated value for the given string key. A null link during the search indicates the inexistence of the key. The following pseudocode implements the search procedure for a given string key in a rooted trie x. In the above pseudocode, x and key correspond to the pointer of the trie's root node and the string key, respectively. The search operation takes O ( m ) {\displaystyle O(m)} time, where m {\displaystyle m} is the size of the string parameter key. In a balanced binary search tree, on the other hand, it takes O ( m log ⁡ n ) {\displaystyle O(m\log n)} time, in the worst case, since key needs to be compared with O ( log ⁡ n ) {\displaystyle O(\log n)} other keys and each comparison takes O ( m ) {\displaystyle O(m)} time, in the worst case. The trie occupies less space, in comparison with a binary search tree, in the case of a large number of short strings, since nodes share common initial string subsequences and store the keys implicitly. === Insertion === Insertion into a trie is guided by using the character sets as indexes to the children array until the last character of the string key is reached. Each node in the trie corresponds to one call of the radix sorting routine, as the trie structure reflects the execution pattern of the top-down radix sort. If null links are encountered before reaching the last character of the string key, new nodes are created. The input value is assigned to the value of the last node traversed, which is the node that corresponds to the key. === Deletion === Deletion of a key–value pair from a trie involves finding the node corresponding to the key, setting its value to null, and recursively removing nodes that have no children. The procedure begins by examining key; an empty string indicates arrival at the node corresponding to the (original) key, in which case its value is set to null. If the node, then, has null value and no children, it is removed from the trie by returning null; otherwise, the node is kept by returning the node itself. == Replacing other data structures == === Replacement for hash tables === A trie can be used to replace a hash table, over which it has the following advantages: Searching for a node with an associated key of size m {\displaystyle m} has the complexity of O ( m ) {\displaystyle O(m)} , whereas an imperfect hash function may have numerous colliding keys, and the worst-case lookup speed of such a table would be O ( N ) {\displaystyle O(N)} , where N {\displaystyle N} denotes the total number of nodes within the table. Tries do not need a hash function for the operation, unlike a hash table; there are also no collisions of different keys in a trie. Within a trie, keys can be efficiently sorted lexicographically. However, tries are less efficient than a hash table when the data is directly accessed on a secondary storage device such as a hard disk drive that has higher random access time than the main memory. == Implementation strategies == Tries can be represented in several ways, corresponding to different trade-offs between memory use and speed of the operations. Using a vector of pointers for representing a trie consumes enormous space; however, memory space can be reduced at the expense of running time if a singly linked list is used for each node vector, as most entries of the vector contains nil {\displaystyle {\text{nil}}} . Techniques such as alphabet reduction may reduce the large space requirements by reinterpreting the original string as a longer string over a smaller alphabet. For example, a string of n bytes can alternatively be regarded as a string of 2n four-bit units. This can reduce memory usage by a factor of eight; but lookups need to visit twice as many nodes in the worst case. Another technique includes storing a vector of 256 ASCII pointers as a bitmap of 256 bits representing ASCII alphabet, which reduces the size of individual nodes dramatically. === Bitwise tries === Bitwise tries are used to address the enormous space requirement for the trie nodes in a naive simple pointer vector implementations. Each character in the string key set is represented via individual bits, which are used to traverse the trie over a string key. The implementations for these types of trie use vectorized CPU instructions to find the first set bit in a fixed-length key input (e.g. GCC's __builtin_clz() intrinsic function). Accordingly, the set bit is used to index the first item, or child node, in the 32- or 64-entry based bitwise tree. Search then proceeds by testing each subsequent bit in the key. This procedure is also cache-local and highly parallelizable due to register independency, and thus performant on out-of-order execution CPUs. === Compressed tries === Radix tree, also known as a compressed trie, is a space-optimized variant of a trie in which any node with only one child gets merged with its parent; elimination of branches of the nodes with a single child results in better metrics in both space and time. This works best when the trie remains static and set of keys stored are very sparse within their representation space. One more approach for static tries is to "pack" the trie by storing disjoint

    Read more →