How to use Dronefly, a Discord chat bot

On the Discord chat platform, we have developed a bot called Dronefly for accessing iNat in conversations. Explore ,help inat while on Discord on a server where Dronefly is present for detailed information. The main ways to interact with the bot are illustrated below.

Observations

Just cut-and-paste an observation link in any channel. Discord itself will preview the image and Dronefly will produce a summary from the important information on the page.

Taxonomy

Type enough words to the ,taxon command (abbreviated ,t) to match. To narrow it down, type the name of the rank. You can also use in to match within another taxon, e.g. ,t prunella in birds to distinguish from Prunella (self-heals). Basic usage is shown below using ,sp, a shortcut for ,taxon species. See ,help inat taxon for more examples.

image

You’ll notice a list of iNat user ids at the bottom. To help others in the conversation review & compare their observations of that taxon, you may click the buttons on the bottom to add or remove yourself or any other user who has shared their iNat profile.

Images

Use the ,image command (abbrevated ,img) to show a taxon’s default image.

image

Sounds

Any observation that has a sound will preview the first one. On the desktop, this shows as an inline player. On mobile, tap the link to download & play on your usual audio player.

Maps

A popular bot feature requested from our Discord users is the ability to list one or more taxa and have it produce a combined range map for all of them:

image

Note: to better see where ranges overlap, individual map layers can be toggled. Look for the “Overlays” icon in the upper right corner and hover over it to open the menu, then tick or untick the checkboxes.

Relatedness

To determine the common ancestor of one or more taxa:

image

More information about a display

To show another image for the most recently shown observation, use ,last obs img:

image

Numerous other ,last subcommands be used to retrieve other information about a taxon or an observation. See ,help inat last to list more examples.

Where do I go to use all this?

You’re welcome to join the unofficial iNaturalist Discord server with this invite link:

https://discord.gg/C57VKVU

Where can I download it?

While most users will simply want to interact with Dronefly already running on Discord, if you’re a developer, you might want to download it & modify it. You can find the project on Github:

https://github.com/synrg/dronefly

Thanks

Thanks to all of the iNat Discord server users for your feature suggestions, testing & feedback that has helped shaped the bot to meet your needs. There are too many of you to list you all!

Some of you have also gone one step further and posted issues to the public issues system & submitted patches which are now included in the code. Thanks for all your contributions!

Thanks also to the Red Discord Bot developers and user community who have written & maintain the bot framework that powers Dronefly. Not only have the produced excellent code without which Dronefly could not exist, but also have personally given me some of their time to review my code & ideas as we worked out the kinks and added new features.

And of course, thanks to the iNaturalist devs who have also been very quick to respond & patient with me as I (sometimes clumsily) have tried to explain what I’m doing & the issues that have arisen while trying to use the iNat API. They’ve been very responsive squashing bugs, taking time to explain how things work, and even adding features to the API that made my job easier & made it possible for me to roll out more features to our users.

17 Likes

Look, ma, I’m on TV!

1 Like

Some general tips for using iNat & Discord together on mobile:

  1. In the iNat app, in the upper right corner of an observation, find the share icon, tap, and Share to Discord. It should default to the channel you last selected, or choose another.
  2. Sharing your profile link on mobile can be done by opening your iNat profile in your web browser instead of the app, then share the page to Discord.
1 Like

Nice total

2 Likes

“new math”

Kidding aside, @auradyme , the number 22 comes from:

https://api.inaturalist.org/v1/observations/species_counts?taxon_id=5212&verifiable=any&user_id=mws,connie147,michaelpirrello,alecc

Or if you want to look at that on the web instead:

https://www.inaturalist.org/observations?place_id=any&taxon_id=5212&user_id=mws,connie147,michaelpirrello,alecc&verifiable=any

Both URLs do now show 22 observations from this set of individuals for this taxon.

It likely happened like this …

Someone could add their name, then add an observation for the taxon afterwards, then someone else can add their name later on, causing the total to be updated as per the above API call. Whatever the observation count was at the time the original person was added will not be changed when the new user is added. Thus, the total at the bottom may not add up to the total of all of the observations from users added in the table earlier. New observations by them would be missing from their individual counts even though they would be included in the total.

I doubt if it’s worth changing how this works for this corner case. Good eye, though!

P.S. to fix, remove the user with the “stale” count & add them again

1 Like