Sure. Read interviews with the agents on blogs and in places like Poets & Writers. Check the acknowledgment pages of books similar to your own. This will give you an idea of the agent's taste. If they represent books with a similar aesthetic, they are probably a good match. Check to see if the agent is a member of AAR, Association of Author Representatives. To be a member, you have to ascribe to their code of ethics and reach a certain level of sales. Subscribe to Publishers Marketplace for a few months (It's not cheap!) to find out who is selling and making deals now.
Ask yourself what do you need from an agent? Do you want an editorial agent, one who will give you detailed feedback and may even ask you to revise the book multiple times before sending it out on submission? Would you rather have an agent who is more hands-off, one who trusts you to find and make the necessary revisions? Do you want an agent who keeps you informed about every rejection? Do you want an agent who checks in with you often or only when there is something important to manage? Is the agent a good communicator? Do you want an agent who is new and building his/her list and is eager to make sales? Or do you prefer an agent who has a list of best selling authors? (Note: This can be good or bad. If the agent is resting on his/her laurels and royalties, he or she may not be that motivated to market a new client in difficult times. Or, the agent may see you as a potential bestseller and put all of their efforts into making that happen. Again, read interviews. Ask questions if you get an offer.) Be aware that the pandemic has changed the way business is done. Some agents are really struggling with social isolation. Others are thriving because they can control their time. Last month's Poets & Writers had a great section of interviews with 11 agents where they all discussed this.
These are all questions you will need to address if you receive an offer of representation. Agents all have their different quirks and personalities, just like anyone, but having a bad agent is worse than not having an agent at all.
So, I would say the "right" agent is a mix of the right personality for your tastes/style with a sales record in your specific genre and/or aesthetic. Unfortunately, it is a bit of a scattergun process, but with practice, you start to get a feel for when something is not the right choice. When I was querying my first novel, I attended a writer's conference where I met a couple of agents that I truly believed would be perfect for me. But after meeting with them and talking to them, I realized I didn't like them very much. Some of it just comes down to trusting your instincts.
JeanneG