view release on metacpan or search on metacpan
lib/LCS/BV.pm view on Meta::CPAN
my ($self,$a,$b) = @_;
#use integer;
#no warnings 'portable'; # for 0xffffffffffffffff
# TODO: maybe faster, if we have fewer expensive iterations
#if (@$a < @$b) {
# my $temp = $a;
# $a = $b;
# $b = $temp;
#}
view all matches for this distribution
view release on metacpan or search on metacpan
--blank-lines-before-packages=0
--iterations=2
--no-outdent-long-comments
-b
-bar
-boc
-ci=4
view all matches for this distribution
view release on metacpan or search on metacpan
--blank-lines-before-packages=0
--iterations=2
--no-outdent-long-comments
-b
-bar
-boc
-ci=4
view all matches for this distribution
view release on metacpan or search on metacpan
t/MyTestHelpers.pm view on Meta::CPAN
#
# use Exporter;
# use vars qw(@ISA @EXPORT_OK %EXPORT_TAGS);
# @ISA = ('Exporter');
# @EXPORT_OK = qw(findrefs
# main_iterations
# warn_suppress_gtk_icon
# glib_gtk_versions
# any_signal_connections
# nowarnings);
# %EXPORT_TAGS = (all => \@EXPORT_OK);
t/MyTestHelpers.pm view on Meta::CPAN
#-----------------------------------------------------------------------------
# Gtk/Glib helpers
# Gtk 2.16 can go into a hard loop on events_pending() / main_iteration_do()
# if dbus is not running, or something like that. In any case limiting the
# iterations is good for test safety.
#
sub main_iterations {
my $count = 0;
if (DEBUG) { MyTestHelpers::diag ("main_iterations() ..."); }
while (Gtk2->events_pending) {
$count++;
Gtk2->main_iteration_do (0);
if ($count >= 500) {
MyTestHelpers::diag ("main_iterations(): oops, bailed out after $count events/iterations");
return;
}
}
MyTestHelpers::diag ("main_iterations(): ran $count events/iterations");
}
# warn_suppress_gtk_icon() is a $SIG{__WARN__} handler which suppresses spam
# from Gtk trying to make you buy the hi-colour icon theme. Eg,
#
t/MyTestHelpers.pm view on Meta::CPAN
while (! $done) {
if (DEBUG >= 2) { MyTestHelpers::diag ("wait_for_event() iteration $count"); }
Gtk2->main_iteration;
$count++;
}
MyTestHelpers::diag ("wait_for_event(): '$signame' ran $count events/iterations\n");
$widget->signal_handler_disconnect ($sig_id);
Glib::Source->remove ($timer_id);
}
view all matches for this distribution
view release on metacpan or search on metacpan
lib/LaTeXML/Plugin/LtxMojo/public/js/external/ace-min/mode-php.js view on Meta::CPAN
define("ace/mode/php",["require","exports","module","ace/lib/oop","ace/mode/text","ace/tokenizer","ace/mode/php_highlight_rules","ace/mode/matching_brace_outdent","ace/range","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cs...
view all matches for this distribution
view release on metacpan or search on metacpan
-npro
-nsfs
--blank-lines-before-packages=0
--opening-hash-brace-right
--no-outdent-long-comments
--iterations=2
-wbb="% + - * / x != == >= <= =~ !~ < > | & >= < = **= += *= &= <<= &&= -= /= |= >>= ||= .= %= ^= x="
view all matches for this distribution
view release on metacpan or search on metacpan
.claude/skills/perl-ai-langertha/SKILL.md view on Meta::CPAN
use Langertha::Raider;
my $raider = Langertha::Raider->new(
engine => $engine, # With MCP servers
mission => 'You are a code reviewer.',
max_iterations => 10, # Max tool rounds per raid
# Optional:
max_context_tokens => 4000,
context_compress_threshold => 0.75,
compression_engine => $cheap_model,
raider_mcp => 1, # Enable self-tools (ask_user, pause, abort)
.claude/skills/perl-ai-langertha/SKILL.md view on Meta::CPAN
$raider->add_history('user', $content); # Replay from DB
$raider->clear_history; # Reset
# Metrics
my $m = $raider->metrics;
say "Iterations: $m->{iterations}";
say "Tool calls: $m->{tool_calls}";
```
### Raid Loop (simplified)
.claude/skills/perl-ai-langertha/SKILL.md view on Meta::CPAN
2. Gather tools from MCP servers + inline tools + self-tools
3. Build conversation: mission + history + new messages
4. Call LLM with tools
5. If tool calls: execute via MCP, add results to conversation, loop
6. If no tool calls: extract final text, persist to history, return result
7. Max iterations safety limit
</raider>
<plugins>
## Plugin System
view all matches for this distribution
view release on metacpan or search on metacpan
.claude/skills/langertha/SKILL.md view on Meta::CPAN
use Langertha::Raider;
my $raider = Langertha::Raider->new(
engine => $engine, # With MCP servers
mission => 'You are a code reviewer.',
max_iterations => 10, # Max tool rounds per raid
# Optional:
max_context_tokens => 4000,
context_compress_threshold => 0.75,
compression_engine => $cheap_model,
raider_mcp => 1, # Enable self-tools (ask_user, pause, abort)
.claude/skills/langertha/SKILL.md view on Meta::CPAN
$raider->add_history('user', $content); # Replay from DB
$raider->clear_history; # Reset
# Metrics
my $m = $raider->metrics;
say "Iterations: $m->{iterations}";
say "Tool calls: $m->{tool_calls}";
```
### Raid Loop (simplified)
.claude/skills/langertha/SKILL.md view on Meta::CPAN
2. Gather tools from MCP servers + inline tools + self-tools
3. Build conversation: mission + history + new messages
4. Call LLM with tools
5. If tool calls: execute via MCP, add results to conversation, loop
6. If no tool calls: extract final text, persist to history, return result
7. Max iterations safety limit
</raider>
<plugins>
## Plugin System
view all matches for this distribution
view release on metacpan or search on metacpan
ex/raider_rag.pl view on Meta::CPAN
);
my $r1 = await $raider->raid_f('What is Moose in Perl? One paragraph.');
printf "Answer:\n%s\n\n", $r1;
printf "Metrics: raids=%d, iterations=%d, tool_calls=%d, time=%.0fms\n",
$raider->metrics->{raids},
$raider->metrics->{iterations},
$raider->metrics->{tool_calls},
$raider->metrics->{time_ms};
}
main()->get;
view all matches for this distribution
view release on metacpan or search on metacpan
t/1-classes/ip.t view on Meta::CPAN
while ( keys %wanted ) {
$iter++;
$ip->dir_go_away;
delete $wanted{ $ip->get_delta->as_string };
}
is(keys %wanted, 0, "go_away went north/east/south/west (in $iter iterations)");
#-- turn left
# cardinal directions
view all matches for this distribution
view release on metacpan or search on metacpan
hugs98-Nov2003/src/static.c view on Meta::CPAN
ps = tl(ps);
if (its++ >= factor*cutoff) {
Cell bpi = inst(in).head;
ERRMSG(inst(in).line) "\n*** Cannot derive " ETHEN ERRPRED(bpi);
ERRTEXT " after %d iterations.", its-1 ETHEN
ERRTEXT
"\n*** This may indicate that the problem is undecidable. However,\n"
ETHEN ERRTEXT
"*** you may still try to increase the cutoff limit using the -c\n"
ETHEN ERRTEXT
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Language/l33t.pm view on Meta::CPAN
before run => sub($self,@) {
die "L0L!!1!1!! n0 l33t pr0gr4m l04d3d, sUxX0r!\n"
unless $self->_has_memory;
};
sub run ( $self, $nbr_iterations = -1 ) {
while ( $self->_iterate ) {
$nbr_iterations-- if $nbr_iterations != -1;
return 1 unless $nbr_iterations;
}
return 0;
}
lib/Language/l33t.pm view on Meta::CPAN
=head2 source( $l33tcode )
Loads and "compiles" the string $l33tcode. If one program was already loaded,
it is clobbered by the newcomer.
=head2 run( [ $nbr_iterations ] )
Runs the loaded program. If $nbr_iterations is given, interupts the program
after this number of iterations even if it hasn't terminated. Returns 0 in
case the program terminated by evaluating an END, 1 if it finished by reaching
$nbr_iterations.
=head2 reset
Reset the interpreter to its initial setting. Code is
recompiled, and pointers reset to their initial values.
view all matches for this distribution
view release on metacpan or search on metacpan
bench/benchmark.pl view on Meta::CPAN
my $x = bench_slot();
print "=== Legba Slot Benchmark ===\n\n";
# Test 1: Getter performance
print "--- Getter Performance (10M iterations) ---\n";
my $result = timethese(10_000_000, {
'slot_getter' => sub { my $v = bench_slot(); },
});
print "\n";
# Test 2: Setter performance
print "--- Setter Performance (10M iterations) ---\n";
$result = timethese(10_000_000, {
'slot_setter' => sub { bench_slot(42); },
});
print "\n";
# Test 3: Mixed get/set
print "--- Mixed Get/Set (5M iterations each) ---\n";
$result = timethese(5_000_000, {
'get_then_set' => sub {
my $v = bench_slot();
bench_slot($v + 1);
},
});
print "\n";
# Test 4: Compare to hash access
print "--- Comparison: Slot vs Hash vs Scalar (10M iterations) ---\n";
my %hash = (bench => 0);
my $scalar = 0;
bench_slot(0);
cmpthese(10_000_000, {
view all matches for this distribution
view release on metacpan or search on metacpan
site/htdocs/static/bwr/angular/angular.js view on Meta::CPAN
* @description
*
* Sets the number of times `$onChanges` hooks can trigger new changes before giving up and
* assuming that the model is unstable.
*
* The current default is 10 iterations.
*
* In complex applications it's possible that dependencies between `$onChanges` hooks and bindings will result
* in several iterations of calls to these hooks. However if an application needs more than the default 10
* iterations to stabilize then you should investigate what is causing the model to continuously change during
* the `$onChanges` hook execution.
*
* Increasing the TTL could have performance implications, so you should not change it without proper justification.
*
* @param {number} limit The number of `$onChanges` hook iterations.
* @returns {number|object} the current limit (or `this` if called as a setter for chaining)
*/
this.onChangesTtl = function(value) {
if (arguments.length) {
TTL = value;
site/htdocs/static/bwr/angular/angular.js view on Meta::CPAN
function flushOnChangesQueue() {
try {
if (!(--onChangesTtl)) {
// We have hit the TTL limit so reset everything
onChangesQueue = undefined;
throw $compileMinErr('infchng', '{0} $onChanges() iterations reached. Aborting!\n', TTL);
}
// We must run this hook in an apply since the $$postDigest runs outside apply
$rootScope.$apply(function() {
for (var i = 0, ii = onChangesQueue.length; i < ii; ++i) {
try {
site/htdocs/static/bwr/angular/angular.js view on Meta::CPAN
* @description
* AngularJS's wrapper for `window.setInterval`. The `fn` function is executed every `delay`
* milliseconds.
*
* The return value of registering an interval function is a promise. This promise will be
* notified upon each tick of the interval, and will be resolved after `count` iterations, or
* run indefinitely if `count` is not defined. The value of the notification will be the
* number of iterations that have run.
* To cancel an interval, call `$interval.cancel(promise)`.
*
* In tests you can use {@link ngMock.$interval#flush `$interval.flush(millis)`} to
* move forward by `millis` milliseconds and trigger any functions scheduled to run in that
* time.
site/htdocs/static/bwr/angular/angular.js view on Meta::CPAN
* @param {number=} [count=0] Number of times to repeat. If not set, or 0, will repeat
* indefinitely.
* @param {boolean=} [invokeApply=true] If set to `false` skips model dirty checking, otherwise
* will invoke `fn` within the {@link ng.$rootScope.Scope#$apply $apply} block.
* @param {...*=} Pass additional parameters to the executed function.
* @returns {promise} A promise which will be notified on each iteration. It will resolve once all iterations of the interval complete.
*
* @example
* <example module="intervalExample" name="interval-service">
* <file name="index.html">
* <script>
site/htdocs/static/bwr/angular/angular.js view on Meta::CPAN
/**
* @ngdoc method
* @name $rootScopeProvider#digestTtl
* @description
*
* Sets the number of `$digest` iterations the scope should attempt to execute before giving up and
* assuming that the model is unstable.
*
* The current default is 10 iterations.
*
* In complex applications it's possible that the dependencies between `$watch`s will result in
* several digest iterations. However if an application needs more than the default 10 digest
* iterations for its model to stabilize then you should investigate what is causing the model to
* continuously change during the digest.
*
* Increasing the TTL could have performance implications, so you should not change it without
* proper justification.
*
* @param {number} limit The number of digest iterations.
*/
/**
* @ngdoc service
site/htdocs/static/bwr/angular/angular.js view on Meta::CPAN
* Processes all of the {@link ng.$rootScope.Scope#$watch watchers} of the current scope and
* its children. Because a {@link ng.$rootScope.Scope#$watch watcher}'s listener can change
* the model, the `$digest()` keeps calling the {@link ng.$rootScope.Scope#$watch watchers}
* until no more listeners are firing. This means that it is possible to get into an infinite
* loop. This function will throw `'Maximum iteration limit exceeded.'` if the number of
* iterations exceeds 10.
*
* Usually, you don't call `$digest()` directly in
* {@link ng.directive:ngController controllers} or in
* {@link ng.$compileProvider#directive directives}.
* Instead, you should call {@link ng.$rootScope.Scope#$apply $apply()} (typically from within
site/htdocs/static/bwr/angular/angular.js view on Meta::CPAN
// `break traverseScopesLoop;` takes us to here
if ((dirty || asyncQueue.length) && !(ttl--)) {
clearPhase();
throw $rootScopeMinErr('infdig',
'{0} $digest() iterations reached. Aborting!\n' +
'Watchers fired in the last 5 iterations: {1}',
TTL, watchLog);
}
} while (dirty || asyncQueue.length);
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Lemplate/Directive.pm view on Meta::CPAN
break
end
$block
end
if not failsafe then
return error("WHILE loop terminated (> $WHILE_MAX iterations)\\n")
end
end
EOF
}
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Lib/CPUInfo.pm view on Meta::CPAN
=item * Counting number of CPUs
Loops: 1,000.
Lib::CPUInfo: Ran 21 iterations (1 outliers).
Lib::CPUInfo: Rounded run time per iteration: 4.163e-04 +/- 1.5e-06 (0.4%)
Sys::Info::Device::CPU: Ran 25 iterations (5 outliers).
Sys::Info::Device::CPU: Rounded run time per iteration: 9.4582e-01 +/- 2.9e-04 (0.0%)
Rex::Inventory::Proc: Ran 21 iterations (0 outliers).
Rex::Inventory::Proc: Rounded run time per iteration: 5.790e-01 +/- 1.1e-03 (0.2%)
=item * Getting the CPU package name
Loops: 1,000.
Lib::CPUInfo: Ran 23 iterations (3 outliers).
Lib::CPUInfo: Rounded run time per iteration: 1.2206e-02 +/- 1.3e-05 (0.1%)
Sys::Info::Device::CPU: Ran 23 iterations (3 outliers).
Sys::Info::Device::CPU: Rounded run time per iteration: 9.6313e-01 +/- 1.0e-03 (0.1%)
=back
=head1 COVERAGE
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Lib/Pepper/Simple.pm view on Meta::CPAN
# SOLUTION: We never call pepFinalize(), keeping the library loaded in memory.
# This allows creating new instances even after all previous instances are destroyed.
#
# Trade-offs:
# PRO: Can create instances â destroy all â create new instances â
# PRO: No -103 errors, can run unlimited test iterations â
# PRO: Simpler lifecycle management â
# CON: Library stays in memory until process exit (~few MB)
# CON: Cannot reset library state without restarting process
#
# Note: Instance-level resources (connections, handles) are still properly cleaned up.
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Lingua/Deva.pm view on Meta::CPAN
say $d->to_latin('सरà¥à¤µà¤®à¥à¥¤'); # 'sarwam।', no warnings
=head1 DESCRIPTION
The C<Lingua::Deva> module provides facilities for converting Sanskrit in
various Latin transliterations to Devanagari and vice-versa. "Deva" is the
name for the Devanagari (I<devanÄgarÄ«>) script according to ISO 15924.
The facilities of this module are exposed through a simple interface in the
form of instances of the L<Lingua::Deva> class. A number of configuration
options can be passed to it during initialization.
view all matches for this distribution
view release on metacpan or search on metacpan
my $name = shift @names;
my $html = shift @html;
print "# $name\n";
print $html;
# skip the transliterations
shift @names;
shift @html;
print "#\n";
print $shavian->transliterate_html($html);
view all matches for this distribution
view release on metacpan or search on metacpan
Nums2Words.pm view on Meta::CPAN
my @CardinalToShortOrdinalMapping;
my $word_case = 'upper';
# At module load time, initialize our static, file-global variables.
# We use these file-global variables to increase performance when one
# needs to compute many iterations for numbers to words. The alternative
# would be to re-instantiate the never-changing variables over and over.
&init_mod_vars;
###############################################################################
###############################################################################
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Lingua/EN/SENNA/third-party/senna/hash/words.lst view on Meta::CPAN
iteq
iter
iterate
iterated
iteration
iterations
iterative
iteratively
itesm
itf
ith
lib/Lingua/EN/SENNA/third-party/senna/hash/words.lst view on Meta::CPAN
translink
translit
translit.
transliterated
transliteration
transliterations
translocated
translocation
translucent
transmarco
transmark
view all matches for this distribution
view release on metacpan or search on metacpan
share/count_1w.txt view on Meta::CPAN
embarrassment 1242414
wiper 1242341
wrappers 1242242
giochi 1242118
spectators 1241932
iterations 1241775
svs 1241680
ntfs 1241647
namespaces 1241562
mismatch 1241513
fdic 1241397
share/count_1w.txt view on Meta::CPAN
modulos 42571
filespace 42571
wondeful 42570
targetname 42570
horngren 42570
transliterations 42569
resultsin 42569
paydays 42569
dwtn 42569
misbegotten 42568
atherectomy 42568
view all matches for this distribution
view release on metacpan or search on metacpan
examples/benchmark.pl view on Meta::CPAN
In my environment (Strawberry Perl 5.10.0.1 on Windows XP Professional with SP3,
AMD Opteron 252 @ 2.6GHz * 2, 2GB RAM):
----------------------------------------------------------------
Benchmark: timing 50000 iterations of Orthography->new, Supersignoj->nova...
Orthography->new: 3 wallclock secs ( 3.22 usr + 0.00 sys = 3.22 CPU) @ 15532.77/s (n=50000)
Supersignoj->nova: 5 wallclock secs ( 4.73 usr + 0.00 sys = 4.73 CPU) @ 10561.89/s (n=50000)
Rate Supersignoj->nova Orthography->new
Supersignoj->nova 10562/s -- -32%
Orthography->new 15533/s 47% --
----------------------------------------------------------------
Benchmark: timing 50000 iterations of Orthography->convert, Supersignoj->transkodigu...
Orthography->convert: 2 wallclock secs ( 1.90 usr + 0.00 sys = 1.90 CPU) @ 26246.72/s (n=50000)
Supersignoj->transkodigu: 10 wallclock secs ( 9.77 usr + 0.00 sys = 9.77 CPU) @ 5119.80/s (n=50000)
Rate Supersignoj->transkodigu Orthography->convert
Supersignoj->transkodigu 5120/s -- -80%
Orthography->convert 26247/s 413% --
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Lingua/FreeLing3/Paragraph.pm view on Meta::CPAN
=head2 C<sentence>
Gets a sentence from a paragraph. Note that this method is extremely
slow, given that FreeLing paragraph is implemented as a
list. Therefore, retrieving the nth element of the list does n
iterations on a linked list.
=cut
sub sentence {
my ($self, $n) = @_;
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Lingua/IT/Ita2heb.pm view on Meta::CPAN
=head1 BUGS AND LIMITATIONS
This program has several known limitations because Italian pronunciation is
sometimes unpredictable and because of the quirks of Hebrew spelling. Do
not assume that transliterations that this program makes are correct
and always check a reliable dictionary to be sure. Look out especially for
the following cases:
=over
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Lingua/Interset/Tagset/FA/Conll.pm view on Meta::CPAN
}
);
# VERB FORM, MOOD, TENSE AND ASPECT ####################
# Here is a website that helps understand Persian verb forms: http://www.jahanshiri.ir/pvc/en/
# Some of the examples below are from the website, some from the PDF documentation of the treebank and some directly from the data.
# The transliterations of the three sources differ.
$atoms{tma} = $self->create_atom
(
'surfeature' => 'tma',
'decode_map' =>
{
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Lingua/JA/FindDates.pod view on Meta::CPAN
A full set of Japanese eras.
=item L<Lingua::JA::Moji>
Japanese character transliterations, including wide ascii numerals.
=back
=head2 Online date converter
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Lingua/Lexicon/IDP/Data/en_fr.txt view on Meta::CPAN
alligator alligator[Noun]
alligators alligators
alligators alligators[Noun]
alliteration allite/ration
alliteration allite/ration[Noun]
alliterations allite/rations
alliterations allite/rations[Noun]
allocate attribuer[Verb]
allocated attibue/, attribue/e[Adjective]
allocation attribution
allocation attribution[Noun]
allocations attibutions
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Lingua/NATools.pm view on Meta::CPAN
This method invoques one of the three algorithms for Entropy
Maximization of the alignment matrix: C<nat-sampleA>, C<nat-sampleB>
and C<nat-ipfp>.
You should call the method with the name of the algorithm ("sampleA",
"sampleB" or "ipfp"), the number of iterations to be done, and the
chunk to be processed.
Returns the time used to run the command.
$pcorpus->run_generic_EM("ipfp", 5, 3);
view all matches for this distribution