Commit Graph

4629 Commits (c11be84d6acb665ff9a6bff3c91193bb010aa813)

Author SHA1 Message Date
Nalin Bhardwaj c11be84d6a Music Chords Diagrams: Fixes/improves triggering (#4085)
* Fixes regex to correctly find values

* Adding multiple naming to instruments

* Fixes #3386

* Adds more sharp/flat aliases for ukulele

* Remove debug print

* Multiple whitespace matching

* Adding support for tabs, chords

* Adding tests
2017-08-15 23:40:48 +01:00
Mariano Simone fe0c18f729 Convert unidecode to use template (#4396)
This is part of #1163
2017-08-15 03:08:36 +05:30
Dragomir Ioan b34a479780 Passphrase, Password: Implemented secure random (#4320)
* Passphrase, Password: Implemented secure random

* Passphrase, Password: Simpler variant of the secure random function

* Passphrase: Removed the initial secure random function

* Passphrase: moved the random generator to its own `sub`
2017-08-14 11:29:20 -04:00
Rob Emery 7b0f4c1fa3 Tips: Smartmatch (~~) is experimental, it is advised to not use it until the behaviour is better defined : http://search.cpan.org/dist/perl-5.18.0/pod/perldelta.pod#The_smartmatch_family_of_features_are_now_experimental (#4424) 2017-08-14 10:06:37 +01:00
Rob Emery e41b5cc966 PrimeFactors: there appears to be an extra character in the tr/// ? (#4426) 2017-08-14 10:05:04 +01:00
Rob Emery f6c8ca8afa Geometry: keys on hashref is fatal under perl 5.24 need to deref into a hash first (#4415) 2017-08-10 12:36:22 +01:00
Zaahir Moolla 96bfdab046 Revert "Roman numerals (improvements) (#4402)" (#4412)
This reverts commit 026279bb6a.
2017-08-09 12:46:46 -04:00
gargaml 026279bb6a Roman numerals (improvements) (#4402)
* First shot at improving roman numeral IA.

Added a new converter.
Added new default settings.
Added some tests.

* Added un upper bound on arabic numbers.

* Remove some typo…

* Added some new triggers.
Allowed uncorrect roman number to load the UI anyway.
Fixed a test.

* Added new triggers.
Fixed regular expressions involved in the UI configuration.
Added new tests.
2017-08-09 11:59:17 +03:00
PJ Hampton 27c5c308de Conversions: Add case sensitivity. Fix ambiguity collisions (#4406)
* Check in work.

* Fix casing ambiguity.

* Fix ambiguity selection.

* break out of outer loop.

* fix YAML
2017-08-08 16:37:13 -04:00
PJ Hampton d17dde90b6 Conversions: US locale defaulting (#4372)
* Add tests to drive development.

Check in work.

Fixed temp triggering ambiguity.

Add experimental conversions US default.

Update the tests.

* Update based on feedback.
2017-08-08 09:46:44 -04:00
PJ Hampton cd0871b9f4 New Timezonetime IA (#4393)
* Check in shivam99aa's work.

* Finish timezone/time IA.

* Refactor Timezonetime.pm

* fix indentation
2017-08-01 12:59:49 -04:00
PJ Hampton 6ba96f8286 Allow asinh and acosh through when triggering. (#4360) 2017-07-18 11:57:22 -04:00
PJ Hampton d5129df6e4 Improve coverage. (#4363) 2017-07-18 11:56:43 -04:00
Philip Kirkbride b082c3013e Palindrome: Convert to Structured (#4352)
* Convert palindrome to structured, tabs, negative tests

* remove comments, simplify subtitle function
2017-07-15 23:14:19 +01:00
PJ Hampton 9c581d9564 Calculator: Various Fixes (#4349)
* Fix weird error message.

* Stop algebra overtriggering.

* Fix overflow error.

* Fixed tests.

* Conclude big patch.

* Patch review bugs.
2017-07-13 18:04:32 -04:00
PJ Hampton 588c354075 New Text Converter IA (#4335)
* Initial commit.

* Prototype up and running.

* Check in work.

* Update work.

* Checking in work.

* Updates based on feedback.

* Code in design.

* Update padding / margin on controls.

* fix mobile styles
2017-07-13 17:46:49 -04:00
Lisa Georgiades b9297e004a Factors: Add support for negative numbers. Add negative cases and tidy (#4245) (#4299)
* Add support for negative numbers. Add negative cases and tidy (#4245)

* Remove extraneous regex match
2017-07-13 13:12:18 -04:00
PJ Hampton 6307864f65 Conversions: Updates UI + Triggering (#4345)
* Fix floz + add n miles.

* Support fractions.

* Update conversions.

* Update based on feedback.
2017-07-13 07:51:16 -04:00
Philip Kirkbride d7f897af3b converting random_name to return structured answer (#4061)
* converting random_name to return structured answer

* altSubtitle typo fix

* altSubtitle typo fix
2017-07-13 07:50:27 -04:00
Philip Kirkbride ab9ce37808 Convert poker goodie to a structured answer, add negative tests (#4350) 2017-07-13 07:43:13 -04:00
Kyle Daruwalla 215857e8dd ColorCodes: Triggers on any query ending in "color <name>" (#4220)
* ColorCodes: Triggers on any query ending in "color <name>"

- Added logic to prevent triggering when excess words are involved in
  the sentence that are not expected

Fixes #3294

* - Fixed regex for filler words to be simpler
- Fixed filler count return statement by removing the double negative

* Simplified regex to catch filler words

* Fixed whitespace changes

* Added more tests for when the IA should not trigger. Existing tests already sufficiently cover when the IA should trigger.
2017-07-12 07:19:17 -04:00
PJ Hampton af0a70222d Calculator: Fixes up trig functions. (#4339)
* Fixes up trig functions.

Replace regex.

* Fixed 1/(x) issues.

* Update dodgy lookahead.
2017-07-10 18:15:49 -04:00
PJ Hampton 8e5cd3f431 Add factorial support. (#4331)
Support factorials. Fix - remove bug.

Fixed a couple of iafd data issues.
2017-07-03 14:02:33 -04:00
PJ Hampton cf799ad23b Conversions: fix spelling. (#4332) 2017-07-02 21:01:55 +01:00
PJ Hampton 0fd68b0912 Conversions: Add expanded triggers. (#4328)
* Add expanded triggers.

* Update triggering / tests.

* Remove convert as a trigger.
2017-06-29 17:29:18 -04:00
PJ Hampton 65f69dab27 Calculator: Various improvements. (#4318)
* Various improvements.

query_nowhitespace removal workaround.

Updated code.

Update code.

Fix exponential state when squaring/cubing

Fix calculator bugs.

* Fix log.

* Various improvements.

* Update variable name.

* Remove debug statements.

* Fix logs/lns on front-end.
2017-06-29 16:55:27 -04:00
PJ Hampton 6457fdeb33 Conversions: Add general triggers. Add aditional aliases. (#4327)
* Add general triggers. Added aditional aliases.

* Remove blocking legacy code.

* Add french word for converter.

* Add missing closing brackets
2017-06-28 11:25:58 -04:00
PJ Hampton e1fe0c8fc0 Add failing tests. (#4325)
Update triggering.

Update triggering scheme.
2017-06-28 09:41:51 -04:00
PJ Hampton ee9d459966 Tips: Add interactivity (#4155)
* initial commit.

* Fixed NaN issue with bill amount.

* Finish up tips.

* Fixed markup.

* Remove mathjs as dep

* Finishing touches...

* Tweak design.

* Add class

* Add simplified css

* overhaul ui

* Add total per person.

* Add secondary text

* Update input class.

* Add further bindings.

* Removed rouge file.
2017-06-23 17:12:52 -04:00
Joshua Liu 9edc2f66bc Molar Mass: Resolve conflicting triggers issue and add new triggers (#4250)
* Molar Mass: Remove conflicting triggers and update tests

* Molar Mass: Increased flexibility of triggers

* Molar Mass: forgot the apostrophe

* Molar Mass: Fix Regex

* Molar Mass: widen triggers
2017-06-23 14:32:59 +01:00
Philip Kirkbride db93ca9b76 Don't trigger log or lg without brackets (as these don't work) (#4249)
* Add sed command example

* Move to file section

* Don't trigger log without brackets. 

Quick fix for issue #4246

* Remove test that uses log(10)

* Update Calculator.t

* dont trigger ln without brackets either

* remove ln and log without bracket tests

* previously removed wrong test bring it back
2017-06-22 16:01:58 +01:00
Billy Barbaro 9a401b5caf Calculator: Comma in Floating Point Numbers (#4199)
* Using detected number style to make sure queries use a . for a decimal and a , to seperate thousands

* Now using method in number styler to prepare numbers for computation.
2017-06-22 15:46:49 +01:00
PJ Hampton e3b649c2ec Conversions: Enable single unit triggers (#4316)
* Add failing tests.

Enable single unit queries.

Add units for triggering.

* Update indentation.
2017-06-21 14:30:34 -04:00
PJ Hampton 5daa945081 Add plural aliases (#4285)
Add speed generic trigs.

Update the natural language triggering scheme.

Update yml file. Remove dep

Reduce yaml file.

mint/mool refactor requests.

Update stuff.
2017-06-20 16:25:14 -04:00
Aastha 4c081b9598 change in Venezuela timezone (VET) (#4296) 2017-06-18 18:38:02 +01:00
Zaahir Moolla 1c867979c1 Conversions: Support single unit input, case-insensitive fallback check (#4261)
* Allow celcisu typo, updated tests accordingly

* Store regex captures in variables

* Allow single unit inputs through guard

* Pass through single unit input to frontend

* Explcitly match guard regex, better check for valid result

* Cleanup whitespace and indentation

* Lowercase symbols that are case-insensitive

* Fix and simplify guard regex

* Better handling of named captures, ensure left unit is not only match

* Case sensitive match first, fall back to lowercase match on symbol

* fix indentation

* remove redundant m on regex match

* Removed default if duplicate.
2017-06-15 15:51:24 +01:00
Aastha 07bbf47634 TimezoneConverter: fixes #4210 fixed error in timezone display (#4262)
* fixed error in timezone display

* minor change

* added new test cases
2017-06-14 21:38:18 +01:00
Zaahir Moolla e9e378f3c3 Conversions: Allow "celcius" typo, updated tests (#4260)
* Allow celcisu typo, updated tests accordingly

* correct typo, move new tests below

* simplify celsius regex
2017-06-09 18:17:11 +02:00
PJ Hampton 60db2ef0ba MolarMass: Fix syntactical error. (#4238)
* Fix syntactical error.

* Decuddle if/elsif/else blocks
2017-06-05 23:08:50 +02:00
PJ Hampton 6d9896cb8b 2048: Tweaks before production (#4027)
* Added additional trigger.

* Fixed container placement / alignment.

* Updated tests.

* Add async start.

* Revert "Add async start."

This reverts commit 54b3edb88221051393d818ccff35d9ae45d10049.

* Check for mobile device and return before onShow

* Ensure we return value from DDH.failed

* remove trailing spaces
2017-06-05 22:49:57 +02:00
PJ Hampton 8c5ac1d651 Conversions: Broaden Triggering (#4239)
* Add triggers to list.

* Remove smart match.

* Stash.

* Broaden triggering.

* Update test formatting.

* Revert "Update test formatting."

This reverts commit 390186743c07bffa5d57025e04926d2473a3ff2e.
Reverting because this creates big conflicts in the PR. We can address
the formatting later

* simply language trigger loading

* Add acronyms for teaspoon

* remove trailing spaces

* Add test for abbreviated teaspoon and tablespoon

* remove trailing spaces
2017-06-05 20:18:18 +02:00
Joshua Liu dbe30f8db7 Molar Mass: New Molar Mass Instant Answer (#4219)
* Add Molar Mass Calculation

* Add molar mass algorithm

* Update Molar Mass Handler

* Molar Mass: added input sanitization

* Molar Mass: Fix sanitation

* Molar Mass: Added tests, Changed mass table, Changed sanitation process

* Molar Mass: Documentation and Formatting

* Molar Mass: Fixed an input sanitation bug and changed instant answer format

* Molar Mass: Remove Boilerplate Comments

* Molar Mass: move data outside of code and add common compound support

* Molar Mass: Change regular expressions

* Molar Mass: Update YAML Format
2017-05-31 20:13:25 +01:00
PJ Hampton 900c5a3da5 Calculator: Fixes onload js issue / Patch triggering (#4230)
* catch value error on load.

* added quick win triggering edge cases from pixel logs.
2017-05-29 07:27:40 -04:00
Rob Emery e3cb2380e9 DatesRole: Adding support for partial time format (#4187)
* DatesRole: Failing tests for new relative date + time format

* DatesRole: Adding support for queries like "03 may 07:00"
2017-05-24 22:36:46 -04:00
PJ Hampton 72729b7c16 Calculator: (URGENT) Fix math.js log|ln simplify issue. (#4183)
* Fix math.js simplify issue.

* Remove debug statements.

* Adds fact to the mix.

* Stash

* Fix greedy quantifier in trig and log/ln

* Don't trigger on anything with stuff after =

* allow triggering on <func> <number>

* Both sides of =

* Fix expressions.

* Tighten up triggering based on valid expressions.

* Remove dumper obj

* Tighten up word triggering.

* Allow only one currency through.

* Kill off symbols in js if allowed through.

* Allow negative numbers.

* Add support for negated numbers.

* Fix initialize issue.

* Refactor code slightly

* Tightened regexs

* Require space between log and input
2017-05-24 17:44:13 -04:00
Robert Badea a588c17f81 html_entities: Added new triggers & tests (#4203)
* added new triggers

* added new test
2017-05-22 14:40:24 -04:00
Shivam Shukla 9ca979f198 Timer: Changed query_raw to query_lc (#4165)
* Timer: Changed query_raw to query_lc
* also fixes #4188 (regression from ambiguous triggers)

* Updated regex and also solve issue #4188

* Added one more test case
2017-05-18 16:54:35 -04:00
Aditya Tandon 8e21782c41 Conversions: Adds generic triggers (#4168)
* adding triggers

* indenting key value pairs

* using smart match

* removing liq vol for now

* shortening regex

* adding test

* removing earlier test but stil it fails

* update test

* formatting test
2017-05-16 15:49:13 +01:00
PJ Hampton 1ce7de6bdb Add in missing duration units. (#4195) 2017-05-12 14:55:36 -04:00
Owen Hines e6bbb3aaf1 Added 'count down' timer trigger (#4180) 2017-05-10 22:23:35 +01:00